@zonos/elements 1.3.274 → 1.3.276
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-660e115c.js → cart-65e8da66.js} +41 -15
- package/dist/cjs/{cleanHtmlMarkdown-31da84b7.js → cleanHtmlMarkdown-57147de7.js} +180 -356
- package/dist/cjs/{collect-286a9d04.js → collect-37c177ab.js} +3 -3
- package/dist/cjs/{debounce-7990f5ea.js → debounce-9a712c79.js} +1 -1
- package/dist/cjs/{getBorderRadius-fc683d94.js → getBorderRadius-4da24d7c.js} +1 -1
- package/dist/cjs/{getContrastColor-d5134ef3.js → getContrastColor-2fb235b8.js} +2 -2
- package/dist/cjs/{hasInclusivePrice-b35e81aa.js → hasInclusivePrice-798ce42d.js} +1 -1
- package/dist/cjs/index.cjs.js +7 -7
- package/dist/cjs/{invoice-f032089f.js → invoice-96f5c802.js} +3 -3
- package/dist/cjs/{isContrastColor-76592c92.js → isContrastColor-ef24b7aa.js} +1 -1
- package/dist/cjs/{isDarkColor-5d6ca405.js → isDarkColor-ebc74b4d.js} +1 -1
- package/dist/cjs/{localization-f4a64f6f.js → localization-90650d7d.js} +61 -1
- package/dist/cjs/{paypal-125259ab.js → paypal-1952f6ec.js} +5 -5
- package/dist/cjs/{placeTestOrder-02001a99.js → placeTestOrder-30191a8f.js} +2 -2
- package/dist/cjs/{renderCheckoutCurrency-cad156a7.js → renderCheckoutCurrency-fd35b4ef.js} +2 -2
- package/dist/cjs/{submitGtag-4906b161.js → submitGtag-74762255.js} +1 -1
- package/dist/cjs/{throttle-02c2e917.js → throttle-34f7abf1.js} +2 -2
- package/dist/cjs/{updateCheckoutSessionAttributes-47d73942.js → updateCheckoutSessionAttributes-f595319d.js} +1 -1
- package/dist/cjs/zonos-address-display_8.cjs.entry.js +444 -202
- package/dist/cjs/zonos-address_4.cjs.entry.js +7 -7
- package/dist/cjs/zonos-airwallex-payment.cjs.entry.js +7 -6
- package/dist/cjs/zonos-badge.cjs.entry.js +1 -1
- package/dist/cjs/zonos-banner.cjs.entry.js +1 -1
- package/dist/cjs/zonos-button_3.cjs.entry.js +3 -3
- package/dist/cjs/zonos-card_5.cjs.entry.js +9 -8
- package/dist/cjs/zonos-cart-items_12.cjs.entry.js +83 -18
- package/dist/cjs/zonos-checkbox_2.cjs.entry.js +3 -3
- package/dist/cjs/zonos-checkout.cjs.entry.js +11 -10
- package/dist/cjs/zonos-collapse.cjs.entry.js +1 -1
- package/dist/cjs/zonos-collect-cart-items_3.cjs.entry.js +7 -6
- package/dist/cjs/zonos-collect-finish_6.cjs.entry.js +12 -11
- package/dist/cjs/zonos-collect.cjs.entry.js +10 -9
- package/dist/cjs/zonos-controller.cjs.entry.js +7 -6
- package/dist/cjs/zonos-country-flag.cjs.entry.js +2 -2
- package/dist/cjs/zonos-country-select_4.cjs.entry.js +1514 -1692
- package/dist/cjs/zonos-hello-dialog.cjs.entry.js +3 -3
- package/dist/cjs/zonos-hello.cjs.entry.js +3 -3
- package/dist/cjs/zonos-input.cjs.entry.js +2 -2
- package/dist/cjs/zonos-invoice-cart-items_2.cjs.entry.js +8 -7
- package/dist/cjs/zonos-invoice-finish_5.cjs.entry.js +12 -11
- package/dist/cjs/zonos-invoice.cjs.entry.js +10 -9
- package/dist/cjs/zonos-language-select_2.cjs.entry.js +2 -2
- package/dist/cjs/zonos-logo.cjs.entry.js +1 -1
- package/dist/cjs/zonos-policy-consent_2.cjs.entry.js +7 -6
- package/dist/cjs/zonos-shipping-rich-radio.cjs.entry.js +5 -5
- package/dist/cjs/zonos-stripe-input.cjs.entry.js +3 -3
- package/dist/cjs/zonos-text.cjs.entry.js +1 -1
- package/dist/cjs/zonos-v-stack.cjs.entry.js +1 -1
- package/dist/collection/components/checkout/zonos-checkout/zonos-cart-subtotal/zonos-cart-subtotal.js +52 -1
- package/dist/collection/components/checkout/zonos-checkout/zonos-checkout.js +1 -1
- package/dist/collection/components/checkout/zonos-checkout/zonos-shipping/zonos-shipping.js +18 -2
- package/dist/collection/components/common/zonos-stripe-phone-input/zonos-stripe-phone-input.js +1 -1
- package/dist/collection/components/main/zonos-controller.js +1 -1
- package/dist/collection/components/store/checkout/cart.js +21 -11
- package/dist/collection/components/store/translationStore/strings.arabic.js +3 -0
- package/dist/collection/components/store/translationStore/strings.base.js +3 -0
- package/dist/collection/components/store/translationStore/strings.chinese.js +3 -0
- package/dist/collection/components/store/translationStore/strings.danish.js +3 -0
- package/dist/collection/components/store/translationStore/strings.dutch.js +3 -0
- package/dist/collection/components/store/translationStore/strings.french.js +3 -0
- package/dist/collection/components/store/translationStore/strings.german.js +3 -0
- package/dist/collection/components/store/translationStore/strings.hebrew.js +3 -0
- package/dist/collection/components/store/translationStore/strings.indonesian.js +3 -0
- package/dist/collection/components/store/translationStore/strings.italian.js +3 -0
- package/dist/collection/components/store/translationStore/strings.japanese.js +3 -0
- package/dist/collection/components/store/translationStore/strings.korean.js +3 -0
- package/dist/collection/components/store/translationStore/strings.norwegian.js +3 -0
- package/dist/collection/components/store/translationStore/strings.polish.js +3 -0
- package/dist/collection/components/store/translationStore/strings.portuguese.js +3 -0
- package/dist/collection/components/store/translationStore/strings.russian.js +3 -0
- package/dist/collection/components/store/translationStore/strings.spanish.js +3 -0
- package/dist/collection/components/store/translationStore/strings.swedish.js +3 -0
- package/dist/collection/components/store/translationStore/strings.turkish.js +3 -0
- package/dist/collection/components/store/translationStore/strings.vietnamese.js +3 -0
- package/dist/collection/components/utils/checkout/isEuDapRemittance.js +15 -0
- package/dist/collection/types/generated/graphql.internal.types.js +78 -0
- package/dist/esm/{cart-23e29950.js → cart-402dcde5.js} +41 -16
- package/dist/esm/{cleanHtmlMarkdown-5f7856f2.js → cleanHtmlMarkdown-87d195f6.js} +180 -356
- package/dist/esm/{collect-a235299d.js → collect-b88fe4ca.js} +3 -3
- package/dist/esm/{debounce-58e4ff3e.js → debounce-c8d67b17.js} +1 -1
- package/dist/esm/{getBorderRadius-d23f47a6.js → getBorderRadius-dc982fe6.js} +1 -1
- package/dist/esm/{getContrastColor-f0bd5b65.js → getContrastColor-af895b60.js} +2 -2
- package/dist/esm/{hasInclusivePrice-5e106f84.js → hasInclusivePrice-1589fef9.js} +1 -1
- package/dist/esm/index.js +7 -7
- package/dist/esm/{invoice-78f069c7.js → invoice-5eb27944.js} +3 -3
- package/dist/esm/{isContrastColor-fbddacb6.js → isContrastColor-089de6ac.js} +1 -1
- package/dist/esm/{isDarkColor-566f04c5.js → isDarkColor-039ef212.js} +1 -1
- package/dist/esm/{localization-17546792.js → localization-d49867ed.js} +61 -1
- package/dist/esm/{paypal-5bc6b0d0.js → paypal-2d4c9d01.js} +5 -5
- package/dist/esm/{placeTestOrder-e842854a.js → placeTestOrder-2ba7c3f2.js} +2 -2
- package/dist/esm/{renderCheckoutCurrency-e3953f67.js → renderCheckoutCurrency-ef71083e.js} +2 -2
- package/dist/esm/{submitGtag-c7ea1f2a.js → submitGtag-dc54f5b9.js} +1 -1
- package/dist/esm/{throttle-f09d0659.js → throttle-44bfb6b5.js} +2 -2
- package/dist/esm/{updateCheckoutSessionAttributes-40e301a4.js → updateCheckoutSessionAttributes-e0a282d9.js} +1 -1
- package/dist/esm/zonos-address-display_8.entry.js +444 -202
- package/dist/esm/zonos-address_4.entry.js +7 -7
- package/dist/esm/zonos-airwallex-payment.entry.js +7 -6
- package/dist/esm/zonos-badge.entry.js +1 -1
- package/dist/esm/zonos-banner.entry.js +1 -1
- package/dist/esm/zonos-button_3.entry.js +3 -3
- package/dist/esm/zonos-card_5.entry.js +9 -8
- package/dist/esm/zonos-cart-items_12.entry.js +83 -18
- package/dist/esm/zonos-checkbox_2.entry.js +3 -3
- package/dist/esm/zonos-checkout.entry.js +11 -10
- package/dist/esm/zonos-collapse.entry.js +1 -1
- package/dist/esm/zonos-collect-cart-items_3.entry.js +7 -6
- package/dist/esm/zonos-collect-finish_6.entry.js +12 -11
- package/dist/esm/zonos-collect.entry.js +10 -9
- package/dist/esm/zonos-controller.entry.js +7 -6
- package/dist/esm/zonos-country-flag.entry.js +2 -2
- package/dist/esm/zonos-country-select_4.entry.js +1514 -1692
- package/dist/esm/zonos-hello-dialog.entry.js +3 -3
- package/dist/esm/zonos-hello.entry.js +3 -3
- package/dist/esm/zonos-input.entry.js +2 -2
- package/dist/esm/zonos-invoice-cart-items_2.entry.js +8 -7
- package/dist/esm/zonos-invoice-finish_5.entry.js +12 -11
- package/dist/esm/zonos-invoice.entry.js +10 -9
- package/dist/esm/zonos-language-select_2.entry.js +2 -2
- package/dist/esm/zonos-logo.entry.js +1 -1
- package/dist/esm/zonos-policy-consent_2.entry.js +7 -6
- package/dist/esm/zonos-shipping-rich-radio.entry.js +5 -5
- package/dist/esm/zonos-stripe-input.entry.js +3 -3
- package/dist/esm/zonos-text.entry.js +1 -1
- package/dist/esm/zonos-v-stack.entry.js +1 -1
- package/dist/esm-es5/cart-402dcde5.js +1 -0
- package/dist/esm-es5/cleanHtmlMarkdown-87d195f6.js +1 -0
- package/dist/esm-es5/{collect-a235299d.js → collect-b88fe4ca.js} +1 -1
- package/dist/esm-es5/{debounce-58e4ff3e.js → debounce-c8d67b17.js} +1 -1
- package/dist/esm-es5/{getBorderRadius-d23f47a6.js → getBorderRadius-dc982fe6.js} +1 -1
- package/dist/esm-es5/{getContrastColor-f0bd5b65.js → getContrastColor-af895b60.js} +1 -1
- package/dist/esm-es5/{hasInclusivePrice-5e106f84.js → hasInclusivePrice-1589fef9.js} +1 -1
- package/dist/esm-es5/index.js +1 -1
- package/dist/esm-es5/{invoice-78f069c7.js → invoice-5eb27944.js} +1 -1
- package/dist/esm-es5/{isContrastColor-fbddacb6.js → isContrastColor-089de6ac.js} +1 -1
- package/dist/esm-es5/{isDarkColor-566f04c5.js → isDarkColor-039ef212.js} +1 -1
- package/dist/esm-es5/localization-d49867ed.js +1 -0
- package/dist/esm-es5/{paypal-5bc6b0d0.js → paypal-2d4c9d01.js} +1 -1
- package/dist/esm-es5/{placeTestOrder-e842854a.js → placeTestOrder-2ba7c3f2.js} +1 -1
- package/dist/esm-es5/{renderCheckoutCurrency-e3953f67.js → renderCheckoutCurrency-ef71083e.js} +1 -1
- package/dist/esm-es5/{submitGtag-c7ea1f2a.js → submitGtag-dc54f5b9.js} +1 -1
- package/dist/esm-es5/throttle-44bfb6b5.js +1 -0
- package/dist/esm-es5/{updateCheckoutSessionAttributes-40e301a4.js → updateCheckoutSessionAttributes-e0a282d9.js} +1 -1
- package/dist/esm-es5/zonos-address-display_8.entry.js +1 -1
- package/dist/esm-es5/zonos-address_4.entry.js +1 -1
- package/dist/esm-es5/zonos-airwallex-payment.entry.js +1 -1
- package/dist/esm-es5/zonos-badge.entry.js +1 -1
- package/dist/esm-es5/zonos-banner.entry.js +1 -1
- package/dist/esm-es5/zonos-button_3.entry.js +1 -1
- package/dist/esm-es5/zonos-card_5.entry.js +1 -1
- package/dist/esm-es5/zonos-cart-items_12.entry.js +1 -1
- package/dist/esm-es5/zonos-checkbox_2.entry.js +1 -1
- package/dist/esm-es5/zonos-checkout.entry.js +1 -1
- package/dist/esm-es5/zonos-collapse.entry.js +1 -1
- package/dist/esm-es5/zonos-collect-cart-items_3.entry.js +1 -1
- package/dist/esm-es5/zonos-collect-finish_6.entry.js +1 -1
- package/dist/esm-es5/zonos-collect.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_4.entry.js +1 -1
- package/dist/esm-es5/zonos-hello-dialog.entry.js +1 -1
- package/dist/esm-es5/zonos-hello.entry.js +1 -1
- package/dist/esm-es5/zonos-input.entry.js +1 -1
- package/dist/esm-es5/zonos-invoice-cart-items_2.entry.js +1 -1
- package/dist/esm-es5/zonos-invoice-finish_5.entry.js +1 -1
- package/dist/esm-es5/zonos-invoice.entry.js +1 -1
- package/dist/esm-es5/zonos-language-select_2.entry.js +1 -1
- package/dist/esm-es5/zonos-logo.entry.js +1 -1
- package/dist/esm-es5/zonos-policy-consent_2.entry.js +1 -1
- package/dist/esm-es5/zonos-shipping-rich-radio.entry.js +1 -1
- package/dist/esm-es5/zonos-stripe-input.entry.js +1 -1
- package/dist/esm-es5/zonos-text.entry.js +1 -1
- package/dist/esm-es5/zonos-v-stack.entry.js +1 -1
- package/dist/scripts/analyticsRelayOnInit.js +1 -1
- package/dist/scripts/blurCurrencyOnInit.js +1 -1
- package/dist/scripts/index.d.ts +11 -0
- package/dist/scripts/index.js +1 -1
- package/dist/scripts/loadZonos.js +1 -1
- package/dist/scripts/zonos.js +1 -1
- package/dist/types/components/checkout/zonos-checkout/zonos-cart-subtotal/zonos-cart-subtotal.d.ts +8 -0
- package/dist/types/components/store/checkout/cart.d.ts +2 -2
- package/dist/types/components/store/translationStore/strings.arabic.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.base.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.chinese.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.danish.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.dutch.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.french.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.german.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.hebrew.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.indonesian.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.italian.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.japanese.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.korean.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.norwegian.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.polish.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.portuguese.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.russian.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.spanish.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.swedish.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.turkish.d.ts +3 -0
- package/dist/types/components/store/translationStore/strings.vietnamese.d.ts +3 -0
- package/dist/types/components/utils/checkout/isEuDapRemittance.d.ts +15 -0
- package/dist/types/types/generated/graphql.internal.types.d.ts +94 -0
- package/dist/types/types/generated/graphql.internal.types.ts +114 -7
- package/dist/zonos-elements/index.esm.js +1 -1
- package/dist/zonos-elements/{p-ccd14aa5.entry.js → p-0745e440.entry.js} +1 -1
- package/dist/zonos-elements/{p-59b10526.entry.js → p-08e78d79.entry.js} +1 -1
- package/dist/zonos-elements/{p-c846a5f3.system.entry.js → p-0ad6a92b.system.entry.js} +1 -1
- package/dist/zonos-elements/p-0b321037.system.entry.js +1 -0
- package/dist/zonos-elements/{p-b59fc3fa.system.entry.js → p-0e1f13ff.system.entry.js} +1 -1
- package/dist/zonos-elements/p-10715fee.system.entry.js +1 -0
- package/dist/zonos-elements/p-144a380d.entry.js +1 -0
- package/dist/zonos-elements/{p-c6823974.system.entry.js → p-15097876.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-9f5fb332.js → p-1735a69b.js} +1 -1
- package/dist/zonos-elements/p-18135660.entry.js +1 -0
- package/dist/zonos-elements/{p-055ef910.entry.js → p-1992fd91.entry.js} +1 -1
- package/dist/zonos-elements/p-1e4dcd29.entry.js +1 -0
- package/dist/zonos-elements/{p-daf57db3.system.entry.js → p-293183c1.system.entry.js} +1 -1
- package/dist/zonos-elements/p-29b60bf3.system.js +1 -1
- package/dist/zonos-elements/{p-a1a05de4.system.entry.js → p-29c1703c.system.entry.js} +1 -1
- package/dist/zonos-elements/p-2e0d813f.system.js +1 -0
- package/dist/zonos-elements/{p-d25759fb.system.js → p-2ea73ca2.system.js} +1 -1
- package/dist/zonos-elements/p-30e9a6d7.system.js +1 -0
- package/dist/zonos-elements/{p-33d4be28.js → p-34d6eb83.js} +1 -1
- package/dist/zonos-elements/p-35fd0fdb.js +1 -0
- package/dist/zonos-elements/p-3b479012.js +1 -0
- package/dist/zonos-elements/{p-d5e66ea6.entry.js → p-3cf22558.entry.js} +1 -1
- package/dist/zonos-elements/p-3cfa4880.js +1 -0
- package/dist/zonos-elements/{p-896fb969.js → p-3d28353a.js} +1 -1
- package/dist/zonos-elements/{p-328fd90e.entry.js → p-3e058b4e.entry.js} +1 -1
- package/dist/zonos-elements/p-3feff726.entry.js +1 -0
- package/dist/zonos-elements/{p-0a54dae6.system.entry.js → p-429ab545.system.entry.js} +1 -1
- package/dist/zonos-elements/p-42ba4da5.system.entry.js +1 -0
- package/dist/zonos-elements/p-45535a81.js +1 -0
- package/dist/zonos-elements/p-48627415.system.entry.js +1 -0
- package/dist/zonos-elements/{p-f053975e.system.js → p-496accce.system.js} +1 -1
- package/dist/zonos-elements/p-4a1c9fa1.entry.js +1 -0
- package/dist/zonos-elements/{p-86a9f048.system.entry.js → p-4a6f9c5e.system.entry.js} +1 -1
- package/dist/zonos-elements/p-4b06044f.js +1 -0
- package/dist/zonos-elements/p-4d29dcc8.entry.js +1 -0
- package/dist/zonos-elements/{p-1f31f5a0.system.entry.js → p-4e6e9a3c.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-12a05647.entry.js → p-4efd7178.entry.js} +1 -1
- package/dist/zonos-elements/p-521cbeea.entry.js +1 -0
- package/dist/zonos-elements/p-534057ad.system.entry.js +1 -0
- package/dist/zonos-elements/p-55195dab.entry.js +1 -0
- package/dist/zonos-elements/p-58b56c69.entry.js +1 -0
- package/dist/zonos-elements/{p-10571f94.system.entry.js → p-5aee5de5.system.entry.js} +1 -1
- package/dist/zonos-elements/p-5c30d04b.js +1 -0
- package/dist/zonos-elements/p-5ce88ef3.system.entry.js +1 -0
- package/dist/zonos-elements/{p-2a1247f4.system.entry.js → p-5d3ea491.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-dcef2202.entry.js → p-5d4201d5.entry.js} +1 -1
- package/dist/zonos-elements/p-5e3b0ef4.entry.js +1 -0
- package/dist/zonos-elements/{p-80df7e0b.system.entry.js → p-6146bfaa.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-e548b8ec.entry.js → p-62609f19.entry.js} +1 -1
- package/dist/zonos-elements/p-628fe742.system.entry.js +1 -0
- package/dist/zonos-elements/{p-91b921a4.system.js → p-647438d6.system.js} +1 -1
- package/dist/zonos-elements/p-67dac4e5.system.entry.js +1 -0
- package/dist/zonos-elements/p-684e27da.system.js +1 -0
- package/dist/zonos-elements/{p-14018649.system.js → p-6ad0f720.system.js} +1 -1
- package/dist/zonos-elements/{p-45d74be2.system.js → p-6f324051.system.js} +1 -1
- package/dist/zonos-elements/p-77ac8bfe.entry.js +1 -0
- package/dist/zonos-elements/{p-4df08fc4.js → p-7bdce9d4.js} +1 -1
- package/dist/zonos-elements/p-82341c15.entry.js +1 -0
- package/dist/zonos-elements/p-864525b4.system.entry.js +1 -0
- package/dist/zonos-elements/p-89befc63.system.entry.js +1 -0
- package/dist/zonos-elements/{p-c83bc4b3.entry.js → p-8c54aaec.entry.js} +1 -1
- package/dist/zonos-elements/{p-306e5499.system.entry.js → p-998f9df5.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-3eba657b.system.entry.js → p-99e8743e.system.entry.js} +1 -1
- package/dist/zonos-elements/p-9fab45aa.system.js +1 -0
- package/dist/zonos-elements/{p-42948a52.js → p-a02ff788.js} +1 -1
- package/dist/zonos-elements/p-a1bd3a53.system.js +1 -0
- package/dist/zonos-elements/{p-e9c8a235.js → p-a3bc7e97.js} +1 -1
- package/dist/zonos-elements/p-a3c116d6.system.js +1 -0
- package/dist/zonos-elements/{p-5aa35d1c.system.entry.js → p-a3d3ce5d.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-27e50593.system.entry.js → p-a44591f6.system.entry.js} +1 -1
- package/dist/zonos-elements/p-a7050d1e.system.entry.js +1 -0
- package/dist/zonos-elements/p-ac1b60c8.system.entry.js +1 -0
- package/dist/zonos-elements/{p-e8cb382e.entry.js → p-ac9b9f7d.entry.js} +1 -1
- package/dist/zonos-elements/{p-2197d6ab.js → p-b1c86a5b.js} +1 -1
- package/dist/zonos-elements/{p-cc508de8.entry.js → p-b5f67807.entry.js} +1 -1
- package/dist/zonos-elements/p-b7e4f1f5.entry.js +1 -0
- package/dist/zonos-elements/p-c209e36d.js +1 -0
- package/dist/zonos-elements/p-c750a2e0.system.entry.js +1 -0
- package/dist/zonos-elements/p-cc6ad18a.js +1 -0
- package/dist/zonos-elements/{p-c1463da7.entry.js → p-d1e84608.entry.js} +1 -1
- package/dist/zonos-elements/{p-9c3276c8.entry.js → p-d5945ddc.entry.js} +1 -1
- package/dist/zonos-elements/{p-5d65be06.system.js → p-d706852e.system.js} +1 -1
- package/dist/zonos-elements/p-d7bda14d.js +1 -0
- package/dist/zonos-elements/{p-df55536b.entry.js → p-daab3824.entry.js} +1 -1
- package/dist/zonos-elements/{p-7d9d2407.system.js → p-dab78981.system.js} +1 -1
- package/dist/zonos-elements/{p-990d1495.system.entry.js → p-db65c60b.system.entry.js} +1 -1
- package/dist/zonos-elements/{p-bc919de1.system.js → p-e977562b.system.js} +1 -1
- package/dist/zonos-elements/{p-abd485df.entry.js → p-ee434a71.entry.js} +1 -1
- package/dist/zonos-elements/{p-3dc3596b.js → p-f1aea919.js} +1 -1
- package/dist/zonos-elements/{p-62c68aee.system.js → p-f2768c92.system.js} +1 -1
- package/dist/zonos-elements/p-f29bcf8b.system.js +1 -0
- package/dist/zonos-elements/{p-1a4083be.system.js → p-f2d50796.system.js} +1 -1
- package/dist/zonos-elements/p-f3a73132.entry.js +1 -0
- package/dist/zonos-elements/{p-f72642de.entry.js → p-f59514e9.entry.js} +1 -1
- package/dist/zonos-elements/{p-52bd7be3.system.js → p-f61c0eef.system.js} +1 -1
- package/dist/zonos-elements/p-ffbf87c8.system.entry.js +1 -0
- package/dist/zonos-elements/zonos-elements.esm.js +1 -1
- package/package.json +12 -35
- package/dist/esm-es5/cart-23e29950.js +0 -1
- package/dist/esm-es5/cleanHtmlMarkdown-5f7856f2.js +0 -1
- package/dist/esm-es5/localization-17546792.js +0 -1
- package/dist/esm-es5/throttle-f09d0659.js +0 -1
- package/dist/zonos-elements/p-013575f2.entry.js +0 -1
- package/dist/zonos-elements/p-08b48608.entry.js +0 -1
- package/dist/zonos-elements/p-0b59076d.system.entry.js +0 -1
- package/dist/zonos-elements/p-14d6542f.system.js +0 -1
- package/dist/zonos-elements/p-1678d8b4.system.entry.js +0 -1
- package/dist/zonos-elements/p-171d0f9f.system.js +0 -1
- package/dist/zonos-elements/p-18af6aaa.system.js +0 -1
- package/dist/zonos-elements/p-1a105d6e.system.entry.js +0 -1
- package/dist/zonos-elements/p-31577ebd.entry.js +0 -1
- package/dist/zonos-elements/p-33910e8b.js +0 -1
- package/dist/zonos-elements/p-3b28fc76.js +0 -1
- package/dist/zonos-elements/p-41619f29.js +0 -1
- package/dist/zonos-elements/p-46e72a90.entry.js +0 -1
- package/dist/zonos-elements/p-49d8a10f.entry.js +0 -1
- package/dist/zonos-elements/p-4a960329.system.entry.js +0 -1
- package/dist/zonos-elements/p-4b371b65.entry.js +0 -1
- package/dist/zonos-elements/p-539bc46c.js +0 -1
- package/dist/zonos-elements/p-5dd86dd9.system.js +0 -1
- package/dist/zonos-elements/p-6c19310e.system.entry.js +0 -1
- package/dist/zonos-elements/p-7eb47eb0.entry.js +0 -1
- package/dist/zonos-elements/p-8af57c2a.js +0 -1
- package/dist/zonos-elements/p-8c4761d1.system.entry.js +0 -1
- package/dist/zonos-elements/p-8e77a3cd.system.entry.js +0 -1
- package/dist/zonos-elements/p-90d22087.system.js +0 -1
- package/dist/zonos-elements/p-919c5500.entry.js +0 -1
- package/dist/zonos-elements/p-9574695a.system.js +0 -1
- package/dist/zonos-elements/p-9581bffb.js +0 -1
- package/dist/zonos-elements/p-97917371.system.entry.js +0 -1
- package/dist/zonos-elements/p-9b003a15.system.entry.js +0 -1
- package/dist/zonos-elements/p-9cd41234.system.entry.js +0 -1
- package/dist/zonos-elements/p-a968ccba.entry.js +0 -1
- package/dist/zonos-elements/p-ac8cfdc0.js +0 -1
- package/dist/zonos-elements/p-ad961f5d.entry.js +0 -1
- package/dist/zonos-elements/p-b5c01288.system.entry.js +0 -1
- package/dist/zonos-elements/p-bf8c98ab.system.js +0 -1
- package/dist/zonos-elements/p-c13d2e3f.entry.js +0 -1
- package/dist/zonos-elements/p-cd34ecf2.js +0 -1
- package/dist/zonos-elements/p-df6fbf3f.entry.js +0 -1
- package/dist/zonos-elements/p-e643346a.entry.js +0 -1
- package/dist/zonos-elements/p-e8ec88a9.system.entry.js +0 -1
- package/dist/zonos-elements/p-e9afd736.system.entry.js +0 -1
- package/dist/zonos-elements/p-f0eb6317.system.entry.js +0 -1
- package/dist/zonos-elements/p-f1cc659c.js +0 -1
- package/dist/zonos-elements/p-f53c8a9f.entry.js +0 -1
- /package/dist/cjs/{zonosStore-45a87908.js → zonosStore-fee716c9.js} +0 -0
- /package/dist/esm/{zonosStore-8e19daff.js → zonosStore-b7d3f9b0.js} +0 -0
- /package/dist/esm-es5/{zonosStore-8e19daff.js → zonosStore-b7d3f9b0.js} +0 -0
- /package/dist/zonos-elements/{p-3e7ee89d.system.js → p-47a1d469.system.js} +0 -0
- /package/dist/zonos-elements/{p-701d9a7c.js → p-9a417eeb.js} +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as o,d as e,h as s,F as t,a as n,g as i}from"./p-ce75b047.js";import{b as a,c as r,t as l,Q as c,F as d,R as h,d as p,u as m,G as f}from"./p-4b06044f.js";import{s as b,c as g,a as u,b as v}from"./p-a02ff788.js";import{t as y,s as z,l as x}from"./p-d7bda14d.js";import{z as w}from"./p-9a417eeb.js";import{h as k,s as C,g as L,i as I,a as S}from"./p-41dd1cb8.js";import{c as j}from"./p-595f5dd2.js";import{g as M}from"./p-f1aea919.js";import{l as Z,b as H}from"./p-0a377722.js";import{i as P,a as _}from"./p-1f3549c6.js";import{c as U}from"./p-b4b7f705.js";import{l as V}from"./p-97aceb11.js";import{c as D}from"./p-a3bc7e97.js";import{r as B}from"./p-45535a81.js";import{p as F}from"./p-3cfa4880.js";import{r as R}from"./p-1b8771bb.js";import"./p-34d6eb83.js";import"./p-6b361d2b.js";import"./p-5c30d04b.js";import"./p-3d28353a.js";const $=class{constructor(s){o(this,s),this.closeClick=e(this,"closeClick",7),this.borderRadius="ROUNDED",this.confirmationId=null,this.isLoading=!0,this.notificationType="success",this.notificationTitle="",this.notificationMessages=[],this.notificationActionText=y("Keep shopping"),this.order=null,this.isWaitingToRedirect=!0,this.pullOrder=async()=>{var o,e;const s=z.checkoutSessionId,t=new URLSearchParams;t.set("checkoutSessionId",s||"");const{baseUrl:n,errors:i,json:a}=await k(`/api/zonos-elements/get-order?${t.toString()}`);return i.length||!(null==a?void 0:a.id)?{baseUrl:n,order:null}:(await(null===(e=(o=w.checkoutSettings).onOrderSuccess)||void 0===e?void 0:e.call(o,{zonosApiRoute:n,zonosOrder:a})),{baseUrl:n,order:a})},this.handleSuccessBehavior=async()=>{this.isLoading=!1,await this.getPullOrder()},this.getPullOrder=async(o=0)=>{var e,s;0===o&&Z("=== Start to poll for order info","info");const{baseUrl:t,order:n}=await this.pullOrder(),i=!!(null===(s=null===(e=null==n?void 0:n.references)||void 0===e?void 0:e.find((o=>"zonosOrderNumber"===(null==o?void 0:o.key))))||void 0===s?void 0:s.value),a=z.checkoutSessionId,r=parseFloat(new URLSearchParams(window.location.search).get("maxPollingRetries")||"0")||30;Z(`=== Polling order (${o} attemps)`,"info"),n?(Z("=== InvoiceOrder info found","info"),o>10&&C({endpoint:`${t}/api/zonos-elements/get-order?checkoutSessionId=${a}&orderId=${n.id}`,errors:[`Invoice order found after ${o} attempts`],metadata:{allLogs:H,checkoutSessionId:z.checkoutSessionId||"",orderId:n.id,storeId:w.storeId}}),this.order=n):n&&i||!(o<r)?C({endpoint:`${t}/api/zonos-elements/get-order?checkoutSessionId=${a}`,errors:[`Invoice order not found after ${r} attempts`],metadata:{allLogs:H,checkoutSessionId:z.checkoutSessionId||"",storeId:w.storeId}}):(await new Promise((o=>setTimeout(o,1e3))),await this.getPullOrder(o+1))},this.checkStripePaymentStatus=async()=>{const o=new URLSearchParams(window.location.search).get("payment_intent_client_secret")||a.clientSecret;if(o||this.storybookForceStatus){const{error:e,messages:s,status:t}=await r({clientSecret:o,storybookForceStatus:this.storybookForceStatus}),n="requires_action"===t||e;this.notificationType=n?"error":"success",this.notificationMessages=s||[],this.notificationTitle=y(n?"Payment failed":"You're all set!"),Z("=== Payment intent retrieve status","info",{clientSecret:o,error:e,messages:s,status:t});const i=new URL(window.location.href);if(i.searchParams.delete("payment_intent_client_secret"),i.searchParams.delete("payment_intent"),i.searchParams.delete("redirect_status"),i.searchParams.delete("zonosCheckoutSessionId"),window.history.replaceState({},"",i.toString()),e&&(null==s?void 0:s.length))b({event:"zonos-checkout-payment-fail"}),C({endpoint:"Stripe payment failed",errors:[`Payment intent "${o.split("_secret_")[0]||o}" status: ${t} - checkout session: ${z.checkoutSessionId}`],metadata:{allLogs:H,credentialToken:window.Zonos.zonosApiKey}});else{b({event:"zonos-checkout-success"}),l({checkoutSessionId:z.checkoutSessionId,eventName:"checkout_orderCompleted"});const o=j("zonos-checkout-success",{message:"Zonos Checkout successfully processed order"});document.dispatchEvent(o),await this.handleSuccessBehavior()}}this.isLoading=!1,c(),d(),z.checkoutSessionId=null},this.checkStagingOrderStatus=async()=>{this.notificationType="success",this.notificationTitle=y("You're all set!"),this.notificationMessages=h("succeeded").messages,await this.handleSuccessBehavior(),c(),d(),g(),z.checkoutSessionId=null},this.checkPaypalPaymentStatus=async()=>{if(u.paypalErrorMessage)return this.notificationType="error",this.notificationTitle=y("Payment failed"),this.notificationMessages=[u.paypalErrorMessage],void(this.isLoading=!1);this.isLoading=!1,u.orderIdCreated&&(b({event:"zonos-checkout-success"}),l({checkoutSessionId:z.checkoutSessionId,eventName:"checkout_orderCompleted"}),this.notificationType="success",this.notificationTitle=y("You're all set!"),this.notificationMessages=h("succeeded").messages,await this.handleSuccessBehavior()),c(),d(),g(),z.checkoutSessionId=null},this.getReceiptUrl=({cartId:o})=>{const e=new URL(`${window.location.origin}/receipt`);e.searchParams.set("referenceId",o),L()&&e.searchParams.set("zonosTestMode","1");const s=new URLSearchParams(window.location.search).get("zonosQaUrl");return s&&e.searchParams.set("zonosQaUrl",s),e.toString()}}componentDidLoad(){if(this.overrideNotification)return this.notificationType=this.overrideNotification.type,this.notificationTitle=this.overrideNotification.title,this.notificationMessages=this.overrideNotification.messages,void(this.isLoading=!1);p.isStagingMode?this.checkStagingOrderStatus():u.orderIdCreated?this.checkPaypalPaymentStatus():this.checkStripePaymentStatus()}render(){const o=window.Zonos.cartId;return s(n,{key:"fc28974043d0f3661919e85aa6cc3839debbac4e",class:"zonos--checkout-finish zonos--elements",style:{"--zonos--border-radius":M({overrideBorderStyle:this.borderRadius})}},!this.isLoading&&s("div",{key:"7a6f37edfde51802035afde1e47184603a81e869",class:"zonos--finish-details"},s("div",{key:"0242af14a36960e490411712bf1c345975d22e28",class:"zonos--group"},s("zonos-icon","success"===this.notificationType?{"aria-label":"Order success",content:'<svg color="var(--zonos-elements-blue-800)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M2 12C2 6.477 6.477 2 12 2s10 4.477 10 10-4.477 10-10 10S2 17.523 2 12Z" data-is-secondary-color="true" fill="var(--zonos-elements-blue-100)" fill-rule="evenodd"></path><path clip-rule="evenodd" d="M15.707 9.293a1 1 0 0 1 0 1.414l-3.646 3.647a1.5 1.5 0 0 1-2.122 0l-1.646-1.647a1 1 0 1 1 1.414-1.414L11 12.586l3.293-3.293a1 1 0 0 1 1.414 0Z" fill="currentColor" fill-rule="evenodd"></path></svg>',iconColor:"blue-800",size:50}:{"aria-label":"Order failed",content:'<svg color="var(--zonos-elements-red-800)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M22 12c0 5.523-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2s10 4.477 10 10Z" data-is-secondary-color="true" fill="var(--zonos-elements-red-200)" fill-rule="evenodd"></path><path clip-rule="evenodd" d="M8.293 8.293a1 1 0 0 1 1.414 0L12 10.586l2.293-2.293a1 1 0 1 1 1.414 1.414L13.414 12l2.293 2.293a1 1 0 0 1-1.414 1.414L12 13.414l-2.293 2.293a1 1 0 0 1-1.414-1.414L10.586 12 8.293 9.707a1 1 0 0 1 0-1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>',iconColor:"red-800",size:50}),s("zonos-text",{key:"ac0bbc63089b78868a2dea35c2d55699e0c677fc",class:"zonos--title",type:"semiBoldSubheader"},this.notificationTitle),this.confirmationId&&s("zonos-badge",{key:"cce14998b08c79a87b5aaf9701d1132e558c0bc6",badgeColor:"gray"},this.confirmationId),s("zonos-text",{key:"c4970d76cbeb63f6dd661bc2c0950ace271f9aac",class:"zonos--subtitle",textColor:"gray-600"},this.notificationMessages.map((o=>s(t,null,o,s("br",null))))),this.order&&o&&s("div",{key:"c79a6fe5bfe1398244a7fbf611430be6f42de16b",class:"zonos--button-container"},s("zonos-button",{key:"c5ab942d9ced619c068b7398a38af5995a8f43ee",onClick:()=>{window.open(this.getReceiptUrl({cartId:o}),"_blank")},size:"lg",variant:"primary"},y("View receipt"))))))}static get assetsDirs(){return["assets"]}};$.style=":host{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--zonos--font-family, Inter), Inter}:host img{max-width:100%}:host dl,:host dd,:host h1,:host h2,:host h3,:host h4,:host h5,:host h6,:host hr,:host figure,:host p,:host pre{margin:0}:host{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}:host{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;height:100%}:host .zonos--group{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;margin-bottom:24px;border-radius:var(--zonos--border-radius, 10px);gap:24px;margin-top:24px;background-color:var(--zonos-elements-gray-50);padding:48px}:host .zonos--finish-details{max-width:640px;min-width:300px;line-height:24px;width:0 auto;margin:auto}:host zonos-button{width:100%}:host .loading-wrapper{min-height:300px;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center}:host .zonos--finish-button-wrapper{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;gap:16px;margin:0 auto;margin-top:48px;max-width:300px}:host .zonos--button-container{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;gap:16px;margin:0 auto}:host .zonos--subtitle{text-align:center}:host .zonos--order-number{background-color:var(--zonos-elements-gray-0);border:1px solid var(--zonos-elements-gray-200);color:var(--zonos-elements-gray-800);border-radius:var(--zonos-elements-radius-6);padding:4px 8px}";const T=class{constructor(e){o(this,e),this.mobile=!1,this.tablet=!1,this.showLanguageDialog=!1,this.isMobile=!1,this.isTablet=!1}handleGlobalClick(o){!this.el.contains(o.target)&&this.showLanguageDialog&&(this.showLanguageDialog=!1)}toggleLanguageDialog(){this.showLanguageDialog=!this.showLanguageDialog}handleMobileChange(){this.isMobile=P(this.mobile)}handleTabletChange(){this.isTablet=_(this.tablet)}componentWillLoad(){this.isMobile=P(this.mobile),this.isTablet=_(this.tablet)}render(){var o;const e=null===(o=V.find((o=>o.code===x.selectedLocale)))||void 0===o?void 0:o.label,t="gray-1000";return s(n,{key:"edea53dbca2832f4f718fd54b74225d9a64b8d01",class:U(["zonos--elements",this.isMobile&&"mobile",this.isTablet&&"tablet"])},s("div",{key:"d2594dfbc8cfff20539e94c279c6096042ee6d00",class:"zonos--invoice-footer"},s("div",{key:"927668578baf306674f56dce375acd1a5e1f335e",class:"zonos--invoice-locale-wrapper"},s("zonos-button",{key:"022b7cb00f7c9ab6305a6ab874f16531f9ab017f",buttonColor:t,class:"zonos--invoice-footer-language-button",icon:s("zonos-icon",{"aria-label":"Language select",content:'<svg width="24" height="24" viewBox="0 0 24 24" fill="none" color="var(--zonos-elements-gray-1000)" xmlns="http://www.w3.org/2000/svg">\n<path fill-rule="evenodd" clip-rule="evenodd" d="M20 12C20 16.4183 16.4183 20 12 20C7.58172 20 4 16.4183 4 12C4 7.58172 7.58172 4 12 4C16.4183 4 20 7.58172 20 12ZM11.4709 5.80634C11.7686 5.53723 11.9541 5.5 12 5.5C12.0459 5.5 12.2314 5.53723 12.5291 5.80634C12.8115 6.06164 13.1289 6.46913 13.4271 7.03651C13.9505 8.03191 14.3838 9.46098 14.48 11.25H9.51996C9.61624 9.46098 10.0495 8.03191 10.5729 7.03651C10.8711 6.46913 11.1885 6.06164 11.4709 5.80634ZM8.01802 11.25C8.11591 9.23031 8.60319 7.55958 9.24516 6.33849C9.29983 6.23451 9.35585 6.13335 9.41312 6.03514C7.32916 6.94017 5.81218 8.90533 5.5428 11.25H8.01802ZM5.5428 12.75H8.01802C8.11591 14.7697 8.60319 16.4404 9.24516 17.6615C9.29983 17.7655 9.35585 17.8666 9.41312 17.9649C7.32916 17.0598 5.81218 15.0947 5.5428 12.75ZM9.51996 12.75H14.48C14.3838 14.539 13.9505 15.9681 13.4271 16.9635C13.1289 17.5309 12.8115 17.9384 12.5291 18.1937C12.2314 18.4628 12.0459 18.5 12 18.5C11.9541 18.5 11.7686 18.4628 11.4709 18.1937C11.1885 17.9384 10.8711 17.5309 10.5729 16.9635C10.0495 15.9681 9.61624 14.539 9.51996 12.75ZM15.982 12.75C15.8841 14.7697 15.3968 16.4404 14.7548 17.6615C14.7002 17.7655 14.6441 17.8666 14.5869 17.9649C16.6708 17.0598 18.1878 15.0947 18.4572 12.75H15.982ZM18.4572 11.25C18.1878 8.90533 16.6708 6.94017 14.5869 6.03514C14.6441 6.13335 14.7002 6.23451 14.7548 6.33849C15.3968 7.55958 15.8841 9.23031 15.982 11.25H18.4572Z" fill="currentColor"/>\n</svg>\n',iconColor:t}),onClick:()=>this.toggleLanguageDialog(),variant:"subtle"},s("span",{key:"88c1b732f19daaace304214d9028f3b6a131e0d2",class:"zonos--invoice-locale-label"},e,s("zonos-icon",{key:"ac383ce2fbcba6b0bd366b8c8126ce10df11d817","aria-hidden":"true",class:"zonos--invoice-locale-chevron",content:'<svg color="var(--zonos-elements-gray-400)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M6.293 9.293a1 1 0 0 1 1.414 0L12 13.586l4.293-4.293a1 1 0 0 1 1.414 1.414l-4.93 4.93a1.1 1.1 0 0 1-1.555 0l-4.93-4.93a1 1 0 0 1 0-1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>',iconColor:t,size:18}))),s("div",{key:"a89f540cdbeb921640f4f466df4c48e12065d90b",class:U(["zonos--invoice-language-dialog",this.showLanguageDialog&&"zonos--invoice-language-dialog-open"])},s("zonos-language-select",{key:"fe017a6300484fc2e657b9f286438f23861a9a96",handleOnClose:()=>this.toggleLanguageDialog()}))),s("div",{key:"b9513e7ab5ee4e809d52074fb2c0950a7ac4bfe5",class:"zonos--invoice-footer-icon-wrapper"},s("div",{key:"55ee92bab8cc5dc6983705b925089cca4083fe42",class:"zonos--invoice-footer-logo"},s("zonos-text",{key:"c8bc7791da058aee313b02797b4555ef5b6ff689",textColor:t},y("Powered by")),s("a",{key:"4493b09d84504d4f797fa0d391cae79ba2266611",href:"https://zonos.com",target:"_blank",title:"Zonos website"},s("zonos-icon",{key:"8c79f8ef0c16d4bb0210e9b7481bc519b97bbddb",autoHeight:!0,content:'<svg width="43" height="10" viewBox="0 0 43 10" fill="none" xmlns="http://www.w3.org/2000/svg">\n<path d="M7.35896 0.0640869H0.30768C0.166068 0.0640869 0.0512695 0.178886 0.0512695 0.320497V1.85896C0.0512695 2.00057 0.166068 2.11537 0.30768 2.11537H4.44439C4.54964 2.11537 4.61005 2.2352 4.54745 2.31982L0.151823 8.2615C0.0865163 8.34978 0.0512695 8.45669 0.0512695 8.56649V9.67947C0.0512695 9.82108 0.166068 9.93588 0.30768 9.93588H7.35896C7.50057 9.93588 7.61537 9.82108 7.61537 9.67947V8.14101C7.61537 7.9994 7.50057 7.8846 7.35896 7.8846H3.22226C3.117 7.8846 3.05659 7.76477 3.11919 7.68015L7.51482 1.73847C7.58013 1.65019 7.61537 1.54328 7.61537 1.43348V0.320497C7.61537 0.178886 7.50057 0.0640869 7.35896 0.0640869Z" fill="var(--zonos-elements-gray-800)"/>\n<path fill-rule="evenodd" clip-rule="evenodd" d="M11.718 0C10.1602 0 8.89746 1.26279 8.89746 2.82051V7.17949C8.89746 8.73721 10.1602 10 11.718 10H13.6411C15.1988 10 16.4616 8.73721 16.4616 7.17949V2.82051C16.4616 1.26279 15.1988 0 13.6411 0H11.718ZM11.718 2.05128C11.2931 2.05128 10.9487 2.39568 10.9487 2.82051V7.17949C10.9487 7.60432 11.2931 7.94872 11.718 7.94872H13.6411C14.0659 7.94872 14.4103 7.60432 14.4103 7.17949V5V2.82051C14.4103 2.39568 14.0659 2.05128 13.6411 2.05128H11.718Z" fill="var(--zonos-elements-gray-800)"/>\n<path d="M17.7437 0.436316V9.71132C17.7437 9.85293 17.8585 9.96773 18.0001 9.96773H19.5385C19.6801 9.96773 19.7949 9.85293 19.7949 9.71132V3.74801C19.7949 3.44829 19.969 3.17587 20.241 3.04996L22.1641 2.15964C22.6739 1.92363 23.2565 2.29592 23.2565 2.85769V9.71132C23.2565 9.85293 23.3713 9.96773 23.5129 9.96773H25.0513C25.193 9.96773 25.3078 9.85293 25.3078 9.71132V2.85595C25.3078 0.79631 23.1718 -0.568775 21.3027 0.296257L19.9742 0.911055C19.8685 0.959946 19.7432 0.931536 19.669 0.84187L19.2748 0.365697C19.1773 0.248019 19.0325 0.179905 18.8797 0.179905H18.0001C17.8585 0.179905 17.7437 0.294704 17.7437 0.436316Z" fill="var(--zonos-elements-gray-800)"/>\n<path fill-rule="evenodd" clip-rule="evenodd" d="M29.4104 0C27.8526 0 26.5898 1.26279 26.5898 2.82051V7.17949C26.5898 8.73721 27.8526 10 29.4104 10H31.3334C32.8912 10 34.1539 8.73721 34.1539 7.17949V2.82051C34.1539 1.26279 32.8912 0 31.3334 0H29.4104ZM29.4104 2.05128C28.9855 2.05128 28.6411 2.39568 28.6411 2.82051V7.17949C28.6411 7.60432 28.9855 7.94872 29.4104 7.94872H31.3334C31.7583 7.94872 32.1027 7.60432 32.1027 7.17949V2.82051C32.1027 2.39568 31.7583 2.05128 31.3334 2.05128H29.4104Z" fill="var(--zonos-elements-gray-800)"/>\n<path d="M38.2085 0.0640869H40.3889C41.8309 0.0640869 42.9999 1.23306 42.9999 2.67506C42.9999 2.79477 42.9108 2.89574 42.792 2.91059L41.1732 3.11293C41.054 3.12784 40.9486 3.03485 40.9486 2.91466C40.9486 2.47322 40.5908 2.11537 40.1493 2.11537H38.3397C37.8688 2.11537 37.4871 2.49712 37.4871 2.96803C37.4871 3.3685 37.7658 3.71501 38.1569 3.80087L40.7916 4.37922C42.0811 4.66229 42.9999 5.80462 42.9999 7.12486C42.9999 8.67735 41.7414 9.93588 40.1889 9.93588H38.0468C36.6048 9.93588 35.4358 8.76691 35.4358 7.32491C35.4358 7.2052 35.5249 7.10423 35.6437 7.08938L37.2625 6.88703C37.3817 6.87213 37.4871 6.96512 37.4871 7.08531C37.4871 7.52675 37.8449 7.8846 38.2864 7.8846H40.1176C40.5765 7.8846 40.9486 7.51252 40.9486 7.05354C40.9486 6.67478 40.6925 6.34394 40.3258 6.24901L37.5136 5.52093C36.2902 5.20422 35.4358 4.10042 35.4358 2.83676C35.4358 1.30545 36.6772 0.0640869 38.2085 0.0640869Z" fill="var(--zonos-elements-gray-700)"/>\n</svg>\n',size:42}))),s("div",{key:"ee6b57b36973750637e0f66f4e883fe7c32acf23",class:"dot"}),s("a",{key:"7aebd09ef1aea4bd9b4a4ed48ffb207e8ed32978",href:"https://zonos.com/docs/legal/zonos-privacy-policy",target:"_blank"},s("zonos-text",{key:"11e7cbb7531b396255374dbf0528f603145bc0b5",textColor:t},y("Privacy policy"))))))}get el(){return i(this)}static get watchers(){return{mobile:["handleMobileChange"],tablet:["handleTabletChange"]}}};T.style=":host{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--zonos--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{position:absolute;bottom:0;left:32px;right:32px;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;z-index:2}:host .zonos--invoice-footer{gap:16px;display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;padding:12px;padding-left:0;-ms-flex-align:center;align-items:center;width:100%}:host .zonos--invoice-footer .zonos--invoice-footer-icon-wrapper{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;gap:16px}:host .zonos--invoice-footer .zonos--invoice-footer-icon-wrapper .zonos--invoice-footer-logo{display:-ms-inline-flexbox;display:inline-flex;gap:8px;-ms-flex-align:center;align-items:center}:host .zonos--invoice-footer .zonos--invoice-footer-icon-wrapper .zonos--invoice-footer-logo a{line-height:0}:host .zonos--invoice-footer .zonos--invoice-footer-icon-wrapper a{text-decoration:none}:host .zonos--invoice-footer zonos-button button.outline{outline:1px solid var(--zonos-elements-gray-800)}:host .zonos--invoice-footer .zonos--invoice-locale-wrapper{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;gap:8px;position:relative}@media (max-width: 400px){:host .zonos--invoice-footer .zonos--invoice-locale-wrapper{gap:4px}}:host .zonos--invoice-footer .zonos--invoice-locale-wrapper .zonos--invoice-locale-label{display:-ms-inline-flexbox;display:inline-flex;-ms-flex-align:center;align-items:center;gap:4px}:host .zonos--invoice-footer .zonos--invoice-language-dialog{position:absolute;bottom:36px;left:var(--language-dialog-left);background:var(--zonos-elements-surface-color);-webkit-box-shadow:var(--zonos-elements-v3-shadow-xl);box-shadow:var(--zonos-elements-v3-shadow-xl);border-radius:var(--zonos-elements-radius-12);width:360px;max-width:100vw;max-height:500px;z-index:2147483011;overflow:auto;-webkit-transform:scale(0);transform:scale(0);-webkit-transform-origin:bottom left;transform-origin:bottom left;opacity:0;-webkit-transition:opacity 0.3s ease-out, -webkit-transform 0.3s ease-out;transition:opacity 0.3s ease-out, -webkit-transform 0.3s ease-out;transition:transform 0.3s ease-out, opacity 0.3s ease-out;transition:transform 0.3s ease-out, opacity 0.3s ease-out, -webkit-transform 0.3s ease-out;-ms-scroll-chaining:none;overscroll-behavior:contain}:host .zonos--invoice-footer .zonos--invoice-language-dialog::-webkit-scrollbar{width:10px}:host .zonos--invoice-footer .zonos--invoice-language-dialog::-webkit-scrollbar-track{background:var(--zonos-elements-gray-50)}:host .zonos--invoice-footer .zonos--invoice-language-dialog::-webkit-scrollbar-thumb{border-radius:10px;background:#cccccc;border:3px solid transparent;background-clip:content-box}:host .zonos--invoice-footer .zonos--invoice-language-dialog::-webkit-scrollbar-thumb:hover{background:#d6d6d6}:host .zonos--invoice-footer .zonos--invoice-language-dialog::-webkit-scrollbar-track{border-top-right-radius:var(--zonos-elements-radius-12);border-bottom-right-radius:var(--zonos-elements-radius-12)}:host .zonos--invoice-footer .zonos--invoice-language-dialog.zonos--invoice-language-dialog-open{opacity:1;-webkit-transform:scale(1);transform:scale(1)}:host .dot{display:-ms-inline-flexbox;display:inline-flex;background:var(--zonos-elements-gray-400);width:6px;height:6px;border-radius:50%}:host(.mobile),:host(.tablet){background-color:var(--zonos-elements-gray-0);width:100%;position:-webkit-sticky;position:sticky;bottom:0}:host(.tablet) .zonos--invoice-footer{width:100%;max-width:800px;-ms-flex-pack:justify;justify-content:space-between;display:-ms-flexbox;display:flex}:host(.mobile){-ms-flex-order:3;order:3}:host(.mobile) .zonos--invoice-locale-wrapper{display:none}:host(.mobile) .zonos--invoice-footer{-ms-flex-pack:center;justify-content:center}";const W=class{constructor(s){o(this,s),this.collapseClicked=e(this,"collapseClicked",7),this.mobile=!0,this.landedCostId="",this.isMobile=!1,this.collapseState=this.collapsed}handleCollapseChangeFromProp(o){this.collapseState=o}handleCollapseChange(o){this.collapseClicked.emit(o)}handleWindowResize(){this.isMobile=I(this.mobile)}componentWillLoad(){this.handleWindowResize()}render(){return s(n,{class:U(["zonos--invoice-order-details zonos--elements",this.isMobile&&"mobile"])},s("div",{class:"zonos--wrapper"},s("button",{class:"zonos--order-details-header",onClick:()=>{this.collapseState=!this.collapseState},type:"button"},s("div",{class:"zonos--order-details-header-text"},s("zonos-text",{type:"boldSubheader"},y("Pay [organizationName]",{organizationName:w.organizationName})),(()=>s("zonos-icon",this.collapseState?{"aria-label":"Collapse expanded section",content:'<svg color="var(--zonos-elements-gray-400)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M6.293 9.293a1 1 0 0 1 1.414 0L12 13.586l4.293-4.293a1 1 0 0 1 1.414 1.414l-4.93 4.93a1.1 1.1 0 0 1-1.555 0l-4.93-4.93a1 1 0 0 1 0-1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>',iconColor:"gray-1200"}:{"aria-label":"Expand collapsed section",content:'<svg color="var(--zonos-elements-gray-400)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M17.707 14.707a1 1 0 0 1-1.414 0L12 10.414l-4.293 4.293a1 1 0 0 1-1.414-1.414l4.93-4.93a1.1 1.1 0 0 1 1.555 0l4.93 4.93a1 1 0 0 1 0 1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>',iconColor:"gray-1200"}))()),s("zonos-text",{type:"boldSubheader"},B({amount:D.amountTotalDue||0,isForeign:!0}))),s("div",{class:"zonos--order-details-wrapper"},s("zonos-collapse",{collapsed:this.collapseState},s("div",{class:"zonos--invoice-order-details-content"},s("zonos-invoice-cart-items",{isMobile:this.isMobile}),s("zonos-invoice-subtotal",{isMobile:this.isMobile}))))))}static get assetsDirs(){return["assets"]}static get watchers(){return{collapsed:["handleCollapseChangeFromProp"],collapseState:["handleCollapseChange"]}}};W.style=":host{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--zonos--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{height:100%}:host *{-ms-scroll-chaining:none;overscroll-behavior:contain}:host *::-webkit-scrollbar{width:10px}:host *::-webkit-scrollbar-track{background:var(--zonos-elements-gray-50)}:host *::-webkit-scrollbar-thumb{border-radius:10px;background:#cccccc;border:3px solid transparent;background-clip:content-box}:host *::-webkit-scrollbar-thumb:hover{background:#d6d6d6}:host .zonos--order-details-header-text{display:-ms-flexbox;display:flex}:host .zonos--wrapper{overflow:auto;background-color:var(--zonos-elements-gray-50);border-radius:16px;height:100%;min-height:56px}:host .zonos--order-details-header-text{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;gap:8px}:host .zonos--order-details-header{position:-webkit-sticky;position:sticky;top:0;z-index:1;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:var(--zonos-elements-gray-50);border:none;display:-ms-flexbox;display:flex;padding:16px 16px 0 16px;width:100%;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-align:center;align-items:center}:host .zonos--order-details-header:focus-visible{outline:none}:host .zonos--order-details-wrapper{position:relative;padding:0 16px 16px 16px}:host .zonos--invoice-order-details-content{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:16px}:host .zonos--invoice-order-info{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:32px}:host .zonos--invoice-order-info .zonos--invoice-order-details-row{display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:16px}:host .zonos--invoice-order-info .zonos--invoice-order-details-row>*{-ms-flex:1 1 150px;flex:1 1 150px}:host .zonos--invoice-order-info .zonos--invoice-order-details-column{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:8px}:host .zonos--invoice-order-info .zonos--invoice-order-shipping-info{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:0}";const N=class{constructor(s){o(this,s),this.continueClicked=e(this,"continueClicked",7),this.paypalSessionFailed=e(this,"paypalSessionFailed",7),this.paypalSessionDone=e(this,"paypalSessionDone",7),this.storeUnsubscribeList=[],this.continueLoading=!1,this.showErrorBanner=!1,this.hasStripePaymentError=!1,this.stagingOrderCreateErrorMessage="",this.internalContinueLoading=this.continueLoading,this.handleValidate=()=>{var o;return!!(null===(o=a.stripePaymentEventData)||void 0===o?void 0:o.complete)},this.continueClickHandler=async({currencyCode:o})=>{var e,s;if(!this.handleValidate())return null===(e=a.stripeBillingAddressElement)||void 0===e||e.getValue(),this.showErrorBanner=!0,null===(s=a.stripeElements)||void 0===s||s.submit(),void setTimeout((()=>{var o;null===(o=this.ele.querySelector("zonos-banner"))||void 0===o||o.scrollIntoView({behavior:"smooth"})}),10);a.checkoutSettlementCurrency=o,b({event:"zonos-checkout-payment-info"}),this.continueClicked.emit()},this.copyCardToClipboard=async o=>{try{await navigator.clipboard.writeText(o)}catch(e){const s=document.createElement("textarea");s.style.position="fixed",s.style.left="-1000px",s.style.top="-1000px",s.style.width="1px",s.style.height="1px",s.value=o,s.id="zonos-copy-card-number",document.body.appendChild(s),s.select(),document.execCommand("copy"),document.body.removeChild(s)}window.Zonos.showNotification({message:y("Card number copied to clipboard"),timeout:4e3,type:"success"})},this.placeTestOrder=async()=>{this.internalContinueLoading=!0;const{errors:o}=await F();if(o.length)return this.stagingOrderCreateErrorMessage=o[0]||"Failed to create staging order. Please try again.",void(this.internalContinueLoading=!1);this.internalContinueLoading=!1,m()}}continueLoadingWatcher(){this.internalContinueLoading=this.continueLoading}stripePaymentErrorWatcher(){this.hasStripePaymentError&&setTimeout((()=>{var o;null===(o=this.ele.querySelector("zonos-banner"))||void 0===o||o.scrollIntoView({behavior:"smooth"})}),50)}componentWillLoad(){this.storeUnsubscribeList=[f("currency",(()=>{v({currency:p.currency})}))],v({currency:p.currency})}disconnectedCallback(){this.storeUnsubscribeList.forEach((o=>o()))}render(){var o;if(this.hasStripePaymentError=a.hasPaymentError,!a.stripeElements)return null;if(!a.clientSecret)return null;this.showErrorBanner&&(this.showErrorBanner=!this.handleValidate());const e=L(),i=p.isStagingMode||S(),r="external_paypal"===(null===(o=a.stripePaymentEventData)||void 0===o?void 0:o.value.type);return s(n,{class:"zonos--checkout-payment zonos--elements"},s("div",{class:"zonos--group"},s("zonos-text",{class:"zonos--title",type:"semiBoldSubheader"},y("Payment method")),(()=>{if(i){const o=w.appearance.theme;return s(t,null,this.stagingOrderCreateErrorMessage&&s("zonos-banner",{class:"zonos--error-banner",intent:"error"},this.stagingOrderCreateErrorMessage),s("zonos-empty-state-payment",{emptyStateText:y("No payment method needed for staging"),theme:o}),s("div",{class:"zonos--group-btn"},s("zonos-button",{backgroundColor:this.submitBtnColor,loading:this.internalContinueLoading,onClick:()=>{this.placeTestOrder()},size:"lg",variant:this.submitBtnType},y("Place test order"))))}return a.isFetchingSession||D.isFetchingPayorInfo?null:s(t,null,this.showErrorBanner&&s("zonos-banner",{class:"zonos--error-banner",intent:"error"},y("Missing required fields. Make sure all fields are completed.")),this.hasStripePaymentError&&s("zonos-banner",{class:"zonos--payment-error-banner",intent:"error"},a.customErrorMessage||y("We couldn't complete your payment. Please verify the payment details and try again.")),u.paypalErrorMessage&&s("zonos-banner",{class:"zonos--payment-error-banner",intent:"error"},u.paypalErrorMessage),s("zonos-payment",null),s("div",{class:"zonos--group-btn"},!r&&s(t,null,s("zonos-button",{backgroundColor:this.submitBtnColor,bold:!0,isDisabled:this.continueLoading&&"USD"===a.checkoutSettlementCurrency,loading:this.continueLoading&&"USD"!==a.checkoutSettlementCurrency,onClick:async()=>{p.checkoutSession?await this.continueClickHandler({currencyCode:p.checkoutSession.subtotals.presentmentCurrencyCode}):Z("Checkout session is not found")},size:"lg",variant:this.submitBtnType},y("Pay [orderTotal]",{orderTotal:B({amount:D.amountTotalDue||0,isForeign:!0})})),a.shouldRenderPayInUsdButton&&s("zonos-button",{class:"zonos--pay-in-base-currency-btn",isDisabled:this.continueLoading&&"USD"!==a.checkoutSettlementCurrency,loading:this.continueLoading&&"USD"===a.checkoutSettlementCurrency,onClick:async()=>{await this.continueClickHandler({currencyCode:"USD"})},size:"lg",variant:"subtle"},y("Click to pay in USD"))),s("zonos-paypal-payment",{onPaypalSessionDone:({detail:{orderId:o}})=>{this.paypalSessionDone.emit(o)},onPaypalSessionFail:()=>this.paypalSessionFailed.emit(),style:{display:r?"block":"none"}})),e&&s("zonos-card",{backgroundColor:"gray-100",borderRadius:12,class:"zonos--test-cards"},s("zonos-v-stack",{spacing:16},s("div",null,s("zonos-text",{type:"semiBoldLabel"},y("Test cards")),s("zonos-text",{textColor:"gray-700"},y("Click to copy the card number. Use any future expiration date and three number CVC."))),s("zonos-button",{icon:s("zonos-icon",{content:'<svg color="var(--zonos-elements-gray-1000)" xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path fill="var(--zonos-elements-gray-1000)" d="M15.342 10.21a.75.75 0 0 0-1.184-.92l-2.978 3.829-1.4-1.4a.75.75 0 1 0-1.06 1.061l1.8 1.8a1 1 0 0 0 1.496-.093l3.326-4.277Z"/><path fill="var(--zonos-elements-gray-1000)" fill-rule="evenodd" d="M12 4a8 8 0 1 0 0 16 8 8 0 0 0 0-16Zm-6.5 8a6.5 6.5 0 1 1 13 0 6.5 6.5 0 0 1-13 0Z" clip-rule="evenodd"/></svg>'}),justifyContent:"flex-start",onClick:()=>this.copyCardToClipboard("4242424242424242")},y("Success")," (****4242)"),s("zonos-button",{icon:s("zonos-icon",{content:'<svg color="var(--zonos-elements-gray-1000)" xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path fill="var(--zonos-elements-gray-1000)" d="M14.475 10.586a.75.75 0 1 0-1.06-1.06L12 10.938l-1.414-1.414a.75.75 0 0 0-1.06 1.06L10.938 12l-1.414 1.414a.75.75 0 1 0 1.06 1.06L12 13.062l1.414 1.414a.75.75 0 0 0 1.06-1.06L13.062 12l1.414-1.414Z"/><path fill="var(--zonos-elements-gray-1000)" fill-rule="evenodd" d="M12 4a8 8 0 1 0 0 16 8 8 0 0 0 0-16Zm-6.5 8a6.5 6.5 0 1 1 13 0 6.5 6.5 0 0 1-13 0Z" clip-rule="evenodd"/></svg>'}),justifyContent:"flex-start",onClick:()=>this.copyCardToClipboard("4000000000000002")},y("Failure")," (****0002)")),s("zonos-notification",null)))})()))}get ele(){return i(this)}static get watchers(){return{continueLoading:["continueLoadingWatcher"],hasStripePaymentError:["stripePaymentErrorWatcher"]}}};N.style=".sc-zonos-invoice-payment-h{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}.sc-zonos-invoice-payment-h *.sc-zonos-invoice-payment{font-family:var(--zonos--font-family, Inter), Inter}.sc-zonos-invoice-payment-h img.sc-zonos-invoice-payment{max-width:100%}.sc-zonos-invoice-payment-h dl.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h dd.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h h1.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h h2.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h h3.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h h4.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h h5.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h h6.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h hr.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h figure.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h p.sc-zonos-invoice-payment,.sc-zonos-invoice-payment-h pre.sc-zonos-invoice-payment{margin:0}.sc-zonos-invoice-payment-h{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}.sc-zonos-invoice-payment-h{overflow:hidden;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex:1;flex:1}.sc-zonos-invoice-payment-h .zonos--title.sc-zonos-invoice-payment{margin-bottom:24px}.sc-zonos-invoice-payment-h .zonos--group.sc-zonos-invoice-payment{margin-bottom:20px;overflow:auto;padding:5px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex:1;flex:1;-ms-scroll-chaining:none;overscroll-behavior:contain}.sc-zonos-invoice-payment-h .zonos--group.sc-zonos-invoice-payment::-webkit-scrollbar{width:10px}.sc-zonos-invoice-payment-h .zonos--group.sc-zonos-invoice-payment::-webkit-scrollbar-track{background:var(--zonos-elements-gray-50)}.sc-zonos-invoice-payment-h .zonos--group.sc-zonos-invoice-payment::-webkit-scrollbar-thumb{border-radius:10px;background:#cccccc;border:3px solid transparent;background-clip:content-box}.sc-zonos-invoice-payment-h .zonos--group.sc-zonos-invoice-payment::-webkit-scrollbar-thumb:hover{background:#d6d6d6}.sc-zonos-invoice-payment-h .zonos--payment-error-banner.sc-zonos-invoice-payment{margin-bottom:8px}.sc-zonos-invoice-payment-h .zonos--error-banner.sc-zonos-invoice-payment{margin-bottom:16px}.sc-zonos-invoice-payment-h zonos-button.sc-zonos-invoice-payment{-webkit-box-shadow:0 0 1px 0 var(--zonos-elements-gray-600);box-shadow:0 0 1px 0 var(--zonos-elements-gray-600)}.sc-zonos-invoice-payment-h .zonos--pay-in-base-currency-btn.sc-zonos-invoice-payment{-webkit-box-shadow:none;box-shadow:none}.sc-zonos-invoice-payment-h .zonos--group-btn.sc-zonos-invoice-payment{position:-webkit-sticky;position:sticky;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-direction:column;flex-direction:column;gap:12px;bottom:-4px;padding-top:12px;background:var(--zonos--primary-color, var(--zonos-elements-gray-0))}.sc-zonos-invoice-payment-h .zonos--group-btn.sc-zonos-invoice-payment zonos-text.sc-zonos-invoice-payment{text-align:center}.sc-zonos-invoice-payment-h .zonos--group-btn.sc-zonos-invoice-payment zonos-button.sc-zonos-invoice-payment{width:100%}.sc-zonos-invoice-payment-h .zonos--test-cards.sc-zonos-invoice-payment{margin-top:auto;padding-top:16px}";const O=class{constructor(e){o(this,e),this.mobile=!1,this.tablet=!1,this.collapsed=!1,this.isMobile=!1,this.isTablet=!1,this.isLoading=!0}handleWindowResize(){this.isMobile=P(this.mobile),this.isTablet=_(this.tablet)}componentWillLoad(){this.handleWindowResize(),setTimeout((()=>{this.isLoading=!1}),1e3)}render(){const o=this.isMobile?"gray-1000":"gray-800";return s(n,{key:"b1dbfed233d47a45ee1e37408d086593049c64d6",class:U(["zonos--invoice-review zonos--elements",this.isMobile&&"mobile",this.isTablet&&"tablet"])},s("div",{key:"fa1cb0796cc5ffd31488c730da1e21f6a7c93c8d",class:"zonos--title"},s("zonos-text",{key:"3759a2ebb1ae8456139fb053d32a64ace12917e7",textColor:o,type:"semiBoldLabel"},y("Pay [organizationName]",{organizationName:w.organizationName}))),s("div",{key:"b5b0c86569fdc26465ea9ac585c5ea5c2b9172bc",class:"zonos--total-pay"},R({content:s("zonos-text",{type:"secondaryPageHeader"},B({amount:D.amountTotalDue||0,isForeign:!0})),isLoading:D.isFetchingPayorInfo,skeletonHeight:"36px",skeletonWidth:"150px"})))}static get assetsDirs(){return["assets"]}};O.style=':host{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--zonos--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{position:-webkit-sticky;position:sticky;top:0;background-color:var(--zonos-elements-gray-0);z-index:1}:host .zonos--total-pay{margin:8px 0 24px;display:-ms-flexbox;display:flex;-ms-flex-positive:1;flex-grow:1;-ms-flex-negative:0;flex-shrink:0;-ms-flex-align:center;align-items:center;gap:48px}:host .zonos--total-pay zonos-text{-ms-flex-negative:0;flex-shrink:0}:host .zonos--total-pay::after{content:"";position:relative;height:1px;width:100%;background:var(--zonos-elements-gray-200)}:host(.mobile),:host(.tablet){display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:8px;padding:4px 0;background-color:transparent;position:relative}:host(.mobile) .zonos--total-pay,:host(.tablet) .zonos--total-pay{margin:0}';export{$ as zonos_invoice_finish,T as zonos_invoice_footer,W as zonos_invoice_order_details,N as zonos_invoice_payment,O as zonos_invoice_review}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{l as o}from"./p-d7bda14d.js";const d="gkjqw123",r="Kq93wqw3",v=()=>{var v;return null===(v=o.inclusivePricingConfigurations)||void 0===v?void 0:v.some((o=>{var v,a;return"ENABLED"===(null===(v=o.configurations[d])||void 0===v?void 0:v.status)||"ENABLED"===(null===(a=o.configurations[r])||void 0===a?void 0:a.status)}))};export{d as D,r as T,v as h}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var __awaiter=this&&this.__awaiter||function(o,n,e,i){function s(o){return o instanceof e?o:new e((function(n){n(o)}))}return new(e||(e=Promise))((function(e,t){function c(o){try{a(i.next(o))}catch(o){t(o)}}function r(o){try{a(i["throw"](o))}catch(o){t(o)}}function a(o){o.done?e(o.value):s(o.value).then(c,r)}a((i=i.apply(o,n||[])).next())}))};var __generator=this&&this.__generator||function(o,n){var e={label:0,sent:function(){if(t[0]&1)throw t[1];return t[1]},trys:[],ops:[]},i,s,t,c;return c={next:r(0),throw:r(1),return:r(2)},typeof Symbol==="function"&&(c[Symbol.iterator]=function(){return this}),c;function r(o){return function(n){return a([o,n])}}function a(r){if(i)throw new TypeError("Generator is already executing.");while(c&&(c=0,r[0]&&(e=0)),e)try{if(i=1,s&&(t=r[0]&2?s["return"]:r[0]?s["throw"]||((t=s["return"])&&t.call(s),0):s.next)&&!(t=t.call(s,r[1])).done)return t;if(s=0,t)r=[r[0]&2,t.value];switch(r[0]){case 0:case 1:t=r;break;case 4:e.label++;return{value:r[1],done:false};case 5:e.label++;s=r[1];r=[0];continue;case 7:r=e.ops.pop();e.trys.pop();continue;default:if(!(t=e.trys,t=t.length>0&&t[t.length-1])&&(r[0]===6||r[0]===2)){e=0;continue}if(r[0]===3&&(!t||r[1]>t[0]&&r[1]<t[3])){e.label=r[1];break}if(r[0]===6&&e.label<t[1]){e.label=t[1];t=r;break}if(t&&e.label<t[2]){e.label=t[2];e.ops.push(r);break}if(t[2])e.ops.pop();e.trys.pop();continue}r=n.call(o,e)}catch(o){r=[6,o];s=0}finally{i=t=0}if(r[0]&5)throw r[1];return{value:r[0]?r[1]:void 0,done:true}}};System.register(["./p-7261e245.system.js","./p-2e0d813f.system.js","./p-2ea73ca2.system.js","./p-6ad0f720.system.js","./p-9fab45aa.system.js","./p-47a1d469.system.js","./p-398d9022.system.js","./p-01174496.system.js","./p-6f23a26a.system.js","./p-23e7c655.system.js","./p-d938f42f.system.js","./p-c9e433c0.system.js","./p-dab78981.system.js","./p-30e9a6d7.system.js","./p-2b8345d8.system.js","./p-d706852e.system.js","./p-e977562b.system.js"],(function(o){"use strict";var n,e,i,s,t,c,r,a,l,v,z,d,h,u,f,m,p,g,b,w,x,y,k,_,C,I,S,j,O,T,E,L,U,P,N,A,D,B,R;return{setters:[function(o){n=o.r;e=o.h;i=o.a;s=o.F},function(o){t=o.b;c=o.i;r=o.c;a=o.d;l=o.n;v=o.e;z=o.j;d=o.k;h=o.w;u=o.C;f=o.H;m=o.F;p=o.f},function(o){g=o.i;b=o.a;w=o.b;x=o.c},function(o){y=o.p;k=o.a},function(o){_=o.s;C=o.t;I=o.e;S=o.h;j=o.l},function(o){O=o.z},function(o){T=o.b},function(o){E=o.h;L=o.s;U=o.l;P=o.g},function(o){N=o.i;A=o.a},function(o){D=o.c},function(o){B=o.l},function(o){R=o.l},function(){},function(){},function(){},function(){},function(){}],execute:function(){var F='<svg color="var(--zonos-elements-gray-400)" fill="none" height="24" viewBox="0 0 24 24" width="24" xmlns="https://www.w3.org/2000/svg"><path clip-rule="evenodd" d="M6.293 9.293a1 1 0 0 1 1.414 0L12 13.586l4.293-4.293a1 1 0 0 1 1.414 1.414l-4.93 4.93a1.1 1.1 0 0 1-1.555 0l-4.93-4.93a1 1 0 0 1 0-1.414Z" fill="currentColor" fill-rule="evenodd"></path></svg>';var V=".sc-zonos-invoice-h{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}.sc-zonos-invoice-h *.sc-zonos-invoice{font-family:var(--zonos--font-family, Inter), Inter}.sc-zonos-invoice-h img.sc-zonos-invoice{max-width:100%}.sc-zonos-invoice-h dl.sc-zonos-invoice,.sc-zonos-invoice-h dd.sc-zonos-invoice,.sc-zonos-invoice-h h1.sc-zonos-invoice,.sc-zonos-invoice-h h2.sc-zonos-invoice,.sc-zonos-invoice-h h3.sc-zonos-invoice,.sc-zonos-invoice-h h4.sc-zonos-invoice,.sc-zonos-invoice-h h5.sc-zonos-invoice,.sc-zonos-invoice-h h6.sc-zonos-invoice,.sc-zonos-invoice-h hr.sc-zonos-invoice,.sc-zonos-invoice-h figure.sc-zonos-invoice,.sc-zonos-invoice-h p.sc-zonos-invoice,.sc-zonos-invoice-h pre.sc-zonos-invoice{margin:0}.sc-zonos-invoice-h{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}.sc-zonos-invoice-h{z-index:2147483647;position:fixed;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;top:0;left:0;width:100%;height:100%;-ms-flex-align:center;align-items:center;background-color:var(--zonos-elements-gray-0)}.sc-zonos-invoice-h *.sc-zonos-invoice{-ms-scroll-chaining:none;overscroll-behavior:contain}.sc-zonos-invoice-h *.sc-zonos-invoice::-webkit-scrollbar{width:10px}.sc-zonos-invoice-h *.sc-zonos-invoice::-webkit-scrollbar-track{background:var(--zonos-elements-gray-50)}.sc-zonos-invoice-h *.sc-zonos-invoice::-webkit-scrollbar-thumb{border-radius:10px;background:#cccccc;border:3px solid transparent;background-clip:content-box}.sc-zonos-invoice-h *.sc-zonos-invoice::-webkit-scrollbar-thumb:hover{background:#d6d6d6}.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice{display:-ms-flexbox;display:flex;height:100%;overflow:hidden;width:100%;-ms-flex-pack:center;justify-content:center}.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--left.sc-zonos-invoice,.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--right.sc-zonos-invoice{-ms-flex:1;flex:1;padding:56px 80px 60px;max-width:800px}.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--left.sc-zonos-invoice{background-color:var(--zonos--primary-color, var(--zonos-elements-gray-0));border-right:1px solid var(--zonos-elements-gray-200);overflow:auto;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:32px}.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--right.sc-zonos-invoice{background-color:var(--zonos-elements-gray-0)}.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--done.sc-zonos-invoice{width:100%;max-width:1400px;max-height:100%;height:calc(100% - 100px);overflow:hidden;-ms-flex-direction:column;flex-direction:column;background-color:var(--zonos-elements-gray-0);-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;padding:24px;padding-bottom:50px}.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--done.sc-zonos-invoice .zonos--header.sc-zonos-invoice{display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-align:center;align-items:center;width:100%}.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--done.sc-zonos-invoice .zonos--logo.sc-zonos-invoice{margin-bottom:0}.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--done.sc-zonos-invoice zonos-checkout-finish.sc-zonos-invoice{-ms-flex:1;flex:1}.sc-zonos-invoice-h .zonos--header-title.sc-zonos-invoice,.sc-zonos-invoice-h .zonos--header-wrapper.sc-zonos-invoice{max-width:800px}.sc-zonos-invoice-h .zonos--left.sc-zonos-invoice{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;position:relative}.sc-zonos-invoice-h .zonos--left.sc-zonos-invoice .zonos--wrapper.sc-zonos-invoice{padding:0 8px 8px}.sc-zonos-invoice-h .zonos--left.sc-zonos-invoice .zonos--payment-error-banner.sc-zonos-invoice{margin-top:24px}.sc-zonos-invoice-h .zonos--right.sc-zonos-invoice{position:relative;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}.sc-zonos-invoice-h .zonos--right.sc-zonos-invoice .zonos--order-details-container.sc-zonos-invoice{overflow:auto}.sc-zonos-invoice-h .zonos--wrapper.sc-zonos-invoice{overflow:auto;max-height:100%;position:relative}.sc-zonos-invoice-h .flex--wrapper.sc-zonos-invoice{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;max-height:100%}.sc-zonos-invoice-h .zonos--logo-wrapper.sc-zonos-invoice{display:-ms-flexbox;display:flex;gap:16px;-ms-flex-align:center;align-items:center;-ms-flex:1;flex:1}.sc-zonos-invoice-h .zonos--logo-wrapper.sc-zonos-invoice>*.sc-zonos-invoice{height:-webkit-fit-content;height:-moz-fit-content;height:fit-content}.sc-zonos-invoice-h .zonos--header-right.sc-zonos-invoice{display:none}.sc-zonos-invoice-h .zonos--logo.sc-zonos-invoice{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}.sc-zonos-invoice-h .zonos--logo.sc-zonos-invoice img.sc-zonos-invoice{max-height:70px;-o-object-position:left center;object-position:left center;-o-object-fit:contain;object-fit:contain}.sc-zonos-invoice-h .zonos--invoice-container.sc-zonos-invoice{overflow:visible}.mobile.sc-zonos-invoice-h,.tablet.sc-zonos-invoice-h{min-width:auto}.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;overflow:auto;border-radius:0;max-height:100%;height:100%;border:0}.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--left.sc-zonos-invoice,.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--right.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--left.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--right.sc-zonos-invoice{padding:12px;padding-bottom:76px}@media (max-width: 768px){.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--left.sc-zonos-invoice,.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--right.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--left.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--right.sc-zonos-invoice{padding-bottom:0}}.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--left.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--left.sc-zonos-invoice{-ms-flex-order:2;order:2;border-right:none}.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--right.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--right.sc-zonos-invoice{-ms-flex-order:1;order:1;padding-top:16px}.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--right.sc-zonos-invoice .zonos--wrapper.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--right.sc-zonos-invoice .zonos--wrapper.sc-zonos-invoice{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;border:var(--zonos-elements-border);border-radius:var(--zonos--border-radius, var(--zonos-elements-radius-10));background-color:var(--zonos-elements-gray-50);padding:12px;margin-top:32px}.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--right.sc-zonos-invoice .zonos--review.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--right.sc-zonos-invoice .zonos--review.sc-zonos-invoice{margin-bottom:0}.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--right.sc-zonos-invoice .zonos--cart-items.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--right.sc-zonos-invoice .zonos--cart-items.sc-zonos-invoice{margin-top:8px}.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice zonos-checkout-footer.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice zonos-checkout-footer.sc-zonos-invoice{-ms-flex-order:3;order:3}.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--wrapper.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--wrapper.sc-zonos-invoice{max-height:100%}.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--footer.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--footer.sc-zonos-invoice{-ms-flex-order:3;order:3}.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--done.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--done.sc-zonos-invoice{width:auto}.mobile.sc-zonos-invoice-h .zonos--cart-subtotal.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--cart-subtotal.sc-zonos-invoice{margin:0}.mobile.sc-zonos-invoice-h .zonos--header-wrapper.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--header-wrapper.sc-zonos-invoice{position:-webkit-sticky;position:sticky;top:0;width:100%;padding:16px;background-color:var(--zonos-elements-gray-0);z-index:3}.mobile.sc-zonos-invoice-h .zonos--header-title.sc-zonos-invoice,.mobile.sc-zonos-invoice-h .zonos--header-wrapper.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--header-title.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--header-wrapper.sc-zonos-invoice{max-width:800px;padding:0 16px}.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice{overflow:auto;-ms-flex-pack:unset;justify-content:unset;-ms-flex-align:center;align-items:center;gap:24px}.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--left.sc-zonos-invoice,.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--right.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--left.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--right.sc-zonos-invoice{overflow:visible;width:100%}.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--right.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--right.sc-zonos-invoice{gap:32px}.mobile.sc-zonos-invoice-h .flex--wrapper.sc-zonos-invoice,.tablet.sc-zonos-invoice-h .flex--wrapper.sc-zonos-invoice{margin-top:0}.mobile.sc-zonos-invoice-h zonos-collect-footer.sc-zonos-invoice,.tablet.sc-zonos-invoice-h zonos-collect-footer.sc-zonos-invoice{-ms-flex-order:3;order:3;left:0}.tablet.sc-zonos-invoice-h .zonos--header-wrapper.sc-zonos-invoice{padding-top:56px;top:-56px}.mobile.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice .zonos--header-right.sc-zonos-invoice{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}.mobile.sc-zonos-invoice-h .zonos--header-wrapper.sc-zonos-invoice{padding-top:28px;top:-28px}.mobile.sc-zonos-invoice-h .zonos--invoice-language-dialog.sc-zonos-invoice{position:fixed;left:0;right:0;bottom:0;-webkit-transform-origin:bottom center;transform-origin:bottom center;width:100vw;background:var(--zonos-elements-surface-color);-webkit-box-shadow:var(--zonos-elements-v3-shadow-xl);box-shadow:var(--zonos-elements-v3-shadow-xl);border-radius:var(--zonos-elements-radius-12);max-width:100vw;max-height:500px;z-index:2147483011;overflow:auto;-webkit-transform:scale(0);transform:scale(0);opacity:0;-webkit-transition:opacity 0.3s ease-out, -webkit-transform 0.3s ease-out;transition:opacity 0.3s ease-out, -webkit-transform 0.3s ease-out;transition:transform 0.3s ease-out, opacity 0.3s ease-out;transition:transform 0.3s ease-out, opacity 0.3s ease-out, -webkit-transform 0.3s ease-out;-ms-scroll-chaining:none;overscroll-behavior:contain}.mobile.sc-zonos-invoice-h .zonos--invoice-language-dialog.sc-zonos-invoice::-webkit-scrollbar{width:10px}.mobile.sc-zonos-invoice-h .zonos--invoice-language-dialog.sc-zonos-invoice::-webkit-scrollbar-track{background:var(--zonos-elements-gray-50)}.mobile.sc-zonos-invoice-h .zonos--invoice-language-dialog.sc-zonos-invoice::-webkit-scrollbar-thumb{border-radius:10px;background:#cccccc;border:3px solid transparent;background-clip:content-box}.mobile.sc-zonos-invoice-h .zonos--invoice-language-dialog.sc-zonos-invoice::-webkit-scrollbar-thumb:hover{background:#d6d6d6}.mobile.sc-zonos-invoice-h .zonos--invoice-language-dialog.sc-zonos-invoice::-webkit-scrollbar-track{border-top-right-radius:var(--zonos-elements-radius-12);border-bottom-right-radius:var(--zonos-elements-radius-12)}.mobile.sc-zonos-invoice-h .zonos--invoice-language-dialog.zonos--invoice-language-dialog-open.sc-zonos-invoice{opacity:1;-webkit-transform:scale(1);transform:scale(1)}.iframed.sc-zonos-invoice-h .zonos--content.sc-zonos-invoice{-ms-scroll-chaining:chained;overscroll-behavior:auto}";var H=V;var K=o("zonos_invoice",function(){function o(o){var e=this;n(this,o);this.storeUnsubscribeList=[];this.onChangeLocaleListener=function(){};this.mobile=false;this.tablet=false;this.stripe=window.Zonos.stripe;this.showLanguageDialogMobile=false;this.submitLoading=false;this.collapseReviewMobile=true;this.isMobile=false;this.isTablet=false;this.isOverlayLoading=true;this.isCartCollected=false;this.isCartExpired=false;this.payInUsdConfirmDialogOpen=false;this.inventoryCheckErrorMessage=null;this.confirmationId=null;this.clientSecret=t.clientSecret;this.stripeCustomerSessionClientSecret=t.stripeCustomerSessionClientSecret;this.getBaseCurrencySettlementInfo=function(){var o=a.selectedLandedCost;if(!o){return null}var n=o.landedCost.amountSubtotals;if(!n){return null}var e=(n.discounts||0)+n.items+n.landedCostTotal+n.shipping;return{settlementAmount:e}};this.applyStripeTheme=function(){return __awaiter(e,void 0,void 0,(function(){var o;return __generator(this,(function(n){switch(n.label){case 0:o=O.appearance.theme;return[4,c({overrideTheme:this.isMobile?o:undefined,paypalEnabled:y()})];case 1:n.sent();return[2]}}))}))};this.fetchCheckoutSession=function(o){return __awaiter(e,void 0,void 0,(function(){var n;return __generator(this,(function(e){switch(e.label){case 0:return[4,E("/api/zonos-elements/collect/get-checkout-session",{body:{checkoutSessionId:o},method:"POST"})];case 1:n=e.sent().json;return[2,n]}}))}))};this.checkStripePaymentIntentStatus=function(){return __awaiter(e,void 0,void 0,(function(){var o,n,e,i,s,c,a,l,v,z;return __generator(this,(function(d){switch(d.label){case 0:n=!!window.Zonos.cartData;e=new URL(window.location.href).searchParams;i=e.get("payment_intent_client_secret");s=e.get("zonosCheckoutSessionId");B("Payment intent exist, checking stripe payment intent status");if(!i){B("No stripe client secret found in the URL, proceed to order if cart data is available");return[2,{shouldAllowOrder:n}]}return[4,r({clientSecret:i})];case 1:c=d.sent(),a=c.error,l=c.status;v=new URLSearchParams(window.location.search).get("redirect_status");if(!(v&&s))return[3,3];if(!a){B("Payment intent is succeeded or in a good state to move forward, show success screen")}else{B("Payment intent failed, show status from error")}return[4,this.fetchCheckoutSession(s)];case 2:z=d.sent();this.confirmationId=((o=z===null||z===void 0?void 0:z.checkoutSession.landedCost)===null||o===void 0?void 0:o.shortId)||null;_.checkoutSessionId=s;t.clientSecret=i;void this.setToFinishStep(l);return[2,{shouldAllowOrder:false}];case 3:if(!n){B("Cart data is not available, only check payment intent status, skip order.");return[2,{shouldAllowOrder:false}]}B("Payment intent is not succeeded, proceed to order");return[2,{shouldAllowOrder:true}]}}))}))}}o.prototype.resizeListener=function(){this.isMobile=N(this.mobile);this.isTablet=A(this.tablet)};o.prototype.setToFinishStep=function(o){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(n){t.stripe=window.Zonos.stripe;a.step="finish";this.storybookPaymentStatusOverride=o;this.isOverlayLoading=false;return[2]}))}))};o.prototype.initInvoiceCart=function(){return __awaiter(this,void 0,void 0,(function(){var o,n,e,i,s,t,c,h,u,f,m,p,w,x,y,k,I,S,j,E,P,N,A;return __generator(this,(function(D){switch(D.label){case 0:if(!window.Zonos.cartData){return[2]}p=(n=(o=window.Zonos.cartData)===null||o===void 0?void 0:o.items[0])===null||n===void 0?void 0:n.currencyCode;if(p){a.currency=p}w=(i=(e=window.Zonos.cartData)===null||e===void 0?void 0:e.references)===null||i===void 0?void 0:i.checkoutSessionId;x=(t=(s=window.Zonos.cartData)===null||s===void 0?void 0:s.references)===null||t===void 0?void 0:t.landedCostId;if(!x){l({messages:[C("Session does not have valid landed cost. Please contact [organizationName] for assistance.",{organizationName:O.organizationName})],title:C("Invalid session")});return[2]}if(w){B("Setting checkout session id from cart reference","info",w);_.checkoutSessionId=w}else{B("Clear checkout session id from storage so we start from a fresh session for the invoice cart");_.checkoutSessionId=null}return[4,this.checkStripePaymentIntentStatus()];case 1:y=D.sent().shouldAllowOrder;if(!y){return[2]}D.label=2;case 2:D.trys.push([2,11,,12]);k=T(window.Zonos.cartData),I=k.adjustments,S=k.cartItems;return[4,v({adjustments:I,cartItems:S,landedCostId:x,shouldInitSessionOnFailure:false})];case 3:D.sent();if(!(!_.checkoutSessionId&&!w))return[3,5];return[4,z()];case 4:j=D.sent();B("stripeStoreInitCheckoutSession: ".concat(j));if(!j){throw new Error("Failed to initialize checkout session! The cart might be created with LIVE Invoice quote but being used with sandbox credential")}D.label=5;case 5:if(!((!a.checkoutSession||((c=a.checkoutSession)===null||c===void 0?void 0:c.completedAt))&&w))return[3,9];return[4,this.fetchCheckoutSession(w)];case 6:E=D.sent();this.confirmationId=((h=E===null||E===void 0?void 0:E.checkoutSession.landedCost)===null||h===void 0?void 0:h.shortId)||null;if(!!(E===null||E===void 0?void 0:E.checkoutSession.completedAt)&&!!E.checkoutSession.order){void this.setToFinishStep("succeeded");return[2]}if(!(E===null||E===void 0?void 0:E.checkoutSession.clientSecret))return[3,8];return[4,r({clientSecret:E.checkoutSession.clientSecret})];case 7:P=D.sent().status;if(P==="processing"||P==="succeeded"){void this.setToFinishStep(P);return[2]}D.label=8;case 8:void L({endpoint:"INVALID_INVOICE_CHECKOUT_SESSION",errors:["Invalid checkout session, can not retrieve the checkout session after failing to update it"],metadata:{cartCheckoutSessionId:w,cartId:(u=window.Zonos.cartData)===null||u===void 0?void 0:u.id,cartLandedCostId:x}});throw new Error("Invalid checkout session, can not retrieve the checkout session after failing to update it");case 9:if(!a.checkoutSession){void L({endpoint:"FAIL_TO_UPDATE_CREATE_INVOICE_CHECKOUT_SESSION",errors:["Could not update/create checkout session for this invoice cart"],metadata:{cartCheckoutSessionId:w||"N/A",cartId:(f=window.Zonos.cartData)===null||f===void 0?void 0:f.id,cartLandedCostId:x||"N/A"}});throw new Error("Could not update/create checkout session for this invoice cart")}void d();N=(m=a.checkoutSession)===null||m===void 0?void 0:m.landedCost;if(!N){throw new Error("Landed cost could not be found in checkout session after creating/updating them")}return[4,g(Object.assign(Object.assign({},a.checkoutSession),{id:_.checkoutSessionId||""}))];case 10:D.sent();void b({landedCostId:N.id});void this.applyStripeTheme();return[3,12];case 11:A=D.sent();U(A);l({messages:[C("Session does not have valid landed cost. Please contact [organizationName] for assistance.",{organizationName:O.organizationName})],title:C("Invalid session")});return[3,12];case 12:this.isOverlayLoading=false;return[2]}}))}))};o.prototype.toggleLanguageDialog=function(){this.showLanguageDialogMobile=!this.showLanguageDialogMobile};o.prototype.handleStripePaymentContinue=function(){return __awaiter(this,void 0,void 0,(function(){var o,n,e,i,s,c,r,l,v;return __generator(this,(function(z){switch(z.label){case 0:void((o=t.stripeBillingAddressElement)===null||o===void 0?void 0:o.getValue());if(!((n=t.stripeLinkEventData)===null||n===void 0?void 0:n.complete)){s=document.querySelector("zonos-link-authentication");s===null||s===void 0?void 0:s.scrollIntoView({behavior:"smooth"});return[2]}if(!((e=t.stripeBillingAddressEventData)===null||e===void 0?void 0:e.complete)){c=document.querySelector(".zonos--billing-address");c===null||c===void 0?void 0:c.scrollIntoView({behavior:"smooth"});return[2]}r=t.checkoutSettlementCurrency==="USD";if(r&&t.shouldRenderPayInUsdButton&&!this.payInUsdConfirmDialogOpen){this.payInUsdConfirmDialogOpen=true;return[2]}this.payInUsdConfirmDialogOpen=false;k.paypalErrorMessage=null;t.hasPaymentError=false;this.submitLoading=true;a.inventoryCheckErrorMessage=null;return[4,h()];case 1:l=z.sent();if(!l){t.hasPaymentError=true;t.customErrorMessage=C("Unable to complete payment in [currency]. Please try again or select a different currency. If the issue persists, contact our support team for assistance.",{currency:t.checkoutSettlementCurrency});this.submitLoading=false;return[2]}return[4,w()];case 2:z.sent();z.label=3;case 3:z.trys.push([3,5,,6]);return[4,u({noLandedCostCheck:true})];case 4:z.sent();a.step="finish";this.confirmationId=x.landedCostShortId||((i=a.selectedLandedCost)===null||i===void 0?void 0:i.landedCostId)||null;return[2];case 5:v=z.sent();U(v);t.hasPaymentError=true;return[3,6];case 6:this.submitLoading=false;return[2]}}))}))};o.prototype.componentWillLoad=function(){var o=this;t.stripe=window.Zonos.stripe;a.step="payment";void this.initInvoiceCart();this.resizeListener();this.storeUnsubscribeList=[f("clientSecret",(function(){void o.applyStripeTheme()})),I("selectedLocale",(function(){void o.applyStripeTheme()}))];B("mobile: ".concat(this.isMobile))};o.prototype.disconnectedCallback=function(){m();p();this.onChangeLocaleListener();this.storeUnsubscribeList.forEach((function(o){return o()}))};o.prototype.render=function(){var o=this;this.clientSecret=t.clientSecret;if(t.stripeCustomerSessionClientSecret){this.stripeCustomerSessionClientSecret=t.stripeCustomerSessionClientSecret}var n=this.getBaseCurrencySettlementInfo();var c=O.appearance,r=c.logoUrl,l=c.theme;var v=function(){var o="".concat(r,"?timestamp=").concat(Date.now());return e("div",{class:"zonos--logo"},o&&e("img",{alt:"".concat(O.organizationName," logo"),src:o}))};var z=P();var d=function(){var n;var i=new URLSearchParams(window.location.search);var t=i.get("zonosQaUrl");var c=i.get("zonosDebug");var r=(n=R.find((function(o){return o.code===j.selectedLocale})))===null||n===void 0?void 0:n.label;return e(s,null,e("zonos-h-stack",{class:"zonos--header-wrapper",spacing:16},e("div",{class:"zonos--logo-wrapper"},v(),z&&e("zonos-badge",{badgeColor:"orange",size:"small"},C("Test mode")),c==="1"&&e("zonos-badge",{badgeColor:"cyan",size:"small"},"debug"),t&&e("zonos-badge",{badgeColor:"purple",size:"small"},t)),e("div",{class:"zonos--header-right"},e("zonos-button",{backgroundColor:"gray-0",class:"zonos--header-right-button",onClick:function(){return o.toggleLanguageDialog()},variant:"outline"},r,e("zonos-icon",{"aria-label":"Language select",content:F,iconColor:"gray-1200"})),e("div",{class:D(["zonos--invoice-language-dialog",o.showLanguageDialogMobile&&"zonos--invoice-language-dialog-open"])},e("zonos-language-select",{handleOnClose:function(){return o.toggleLanguageDialog()}})))))};var h=function(){if(o.isOverlayLoading||t.isFetchingSession){return null}return e("div",{class:"zonos--content"},a.step!=="finish"&&a.step!=="error"&&e(s,null,(o.isMobile||o.isTablet)&&d(),e("div",{class:"zonos--left","data-theme":l},!o.isMobile&&!o.isTablet&&d(),e("zonos-text",{class:"zonos--title",type:"semiBoldSubheader"},C("Billing info")),e("zonos-v-stack",{spacing:16},e("zonos-link-authentication",{titleText:""}),e("zonos-address",{titleText:"",type:"billing"})),e("zonos-invoice-payment",{class:D(["zonos--invoice-container"]),continueLoading:o.submitLoading,onContinueClicked:function(){return __awaiter(o,void 0,void 0,(function(){return __generator(this,(function(o){switch(o.label){case 0:return[4,this.handleStripePaymentContinue()];case 1:o.sent();return[2]}}))}))}})),e("div",{class:"zonos--right","data-theme":l},!o.isMobile&&e("zonos-invoice-review",{mobile:o.isMobile,tablet:o.isTablet}),e("div",{class:"zonos--order-details-container"},!o.isMobile&&e("zonos-invoice-cart-items",null),o.isMobile&&e("zonos-invoice-order-details",{collapsed:o.collapseReviewMobile,mobile:o.isMobile,onCollapseClicked:function(){o.collapseReviewMobile=!o.collapseReviewMobile}})),e("div",{class:"flex--wrapper"},!o.isMobile&&e("zonos-v-stack",{spacing:16},e("zonos-invoice-subtotal",null)),!o.isMobile&&!o.isTablet&&e("zonos-invoice-footer",{"data-theme":l,mobile:o.isMobile,tablet:o.isTablet})))),(a.step==="finish"||a.step==="error")&&e("div",{class:"zonos--done","data-theme":l},e("div",{class:"zonos--header"},v()),e("zonos-invoice-finish",{confirmationId:o.confirmationId,overrideNotification:a.step==="error"&&!!a.error?Object.assign(Object.assign({},a.error),{type:"error"}):undefined,storybookForceStatus:o.storybookPaymentStatusOverride})),(o.isMobile||o.isTablet||a.step==="finish"||a.step==="error")&&e("zonos-invoice-footer",{"data-theme":l,mobile:o.isMobile,tablet:o.isTablet}))};return e(i,{class:D(["zonos--invoice zonos--elements",this.isMobile&&"mobile",this.isTablet&&"tablet"]),"data-theme":l},h(),n&&e("zonos-confirm-dialog",{class:"zonos--pay-in-usd-dialog",dialogCancelBtnText:C("Cancel"),dialogConfirmBtnText:C("Pay [orderTotal]",{orderTotal:S({amount:n.settlementAmount,currency:"USD"})}),dialogIntent:"warn",dialogOpen:this.payInUsdConfirmDialogOpen,dialogSubtitle:C("By paying in USD, your card will be charged directly with no currency conversion. However, using a non-USD based card may result in additional currency conversion fees at the bank level."),dialogTitle:C("Pay in USD (United States Dollar)?"),dialogType:"confirm",dialogWidth:480,onCancelClicked:function(){o.payInUsdConfirmDialogOpen=false},onConfirmClicked:function(){return o.handleStripePaymentContinue()}}),e("zonos-loading-overlay",{open:this.isOverlayLoading}))};Object.defineProperty(o,"assetsDirs",{get:function(){return["assets"]},enumerable:false,configurable:true});return o}());K.style=H}}}));
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
function n(n,t){return Array(t+1).join(n)}function t(n){return n.replace(/^\n*/,"")}function r(n){for(var t=n.length;t>0&&"\n"===n[t-1];)t--;return n.substring(0,t)}function e(n){return r(t(n))}var i=["ADDRESS","ARTICLE","ASIDE","AUDIO","BLOCKQUOTE","BODY","CANVAS","CENTER","DD","DIR","DIV","DL","DT","FIELDSET","FIGCAPTION","FIGURE","FOOTER","FORM","FRAMESET","H1","H2","H3","H4","H5","H6","HEADER","HGROUP","HR","HTML","ISINDEX","LI","MAIN","MENU","NAV","NOFRAMES","NOSCRIPT","OL","OUTPUT","P","PRE","SECTION","TABLE","TBODY","TD","TFOOT","TH","THEAD","TR","UL"];function u(n){return a(n,i)}var f=["AREA","BASE","BR","COL","COMMAND","EMBED","HR","IMG","INPUT","KEYGEN","LINK","META","PARAM","SOURCE","TRACK","WBR"];function o(n){return a(n,f)}var c=["A","TABLE","THEAD","TBODY","TFOOT","TH","TD","IFRAME","SCRIPT","AUDIO","VIDEO"];function a(n,t){return t.indexOf(n.nodeName)>=0}function l(n,t){return n.getElementsByTagName&&t.some((function(t){return n.getElementsByTagName(t).length}))}var s=[[/\\/g,"\\\\"],[/\*/g,"\\*"],[/^-/g,"\\-"],[/^\+ /g,"\\+ "],[/^(=+)/g,"\\$1"],[/^(#{1,6}) /g,"\\$1 "],[/`/g,"\\`"],[/^~~~/g,"\\~~~"],[/\[/g,"\\["],[/\]/g,"\\]"],[/^>/g,"\\>"],[/_/g,"\\_"],[/^(\d+)\. /g,"$1\\. "]];function h(n){return s.reduce((function(n,t){return n.replace(t[0],t[1])}),n)}var v={};function g(n){return n?n.replace(/(\n+\s*)+/g,"\n"):""}function E(n){var t=n.replace(/([<>()])/g,"\\$1");return t.indexOf(" ")>=0?"<"+t+">":t}function m(n){return n.replace(/"/g,'\\"')}function d(n){for(var t in this.options=n,this._keep=[],this._remove=[],this.blankRule={replacement:n.blankReplacement},this.keepReplacement=n.keepReplacement,this.defaultRule={replacement:n.defaultReplacement},this.array=[],n.rules)this.array.push(n.rules[t])}function p(n,t,r){for(var e=0;e<n.length;e++){var i=n[e];if(A(i,t,r))return i}}function A(n,t,r){var e=n.filter;if("string"==typeof e){if(e===t.nodeName.toLowerCase())return!0}else if(Array.isArray(e)){if(e.indexOf(t.nodeName.toLowerCase())>-1)return!0}else{if("function"!=typeof e)throw new TypeError("`filter` needs to be a string, array, or function");if(e.call(n,t,r))return!0}}function R(n){var t=n.nextSibling||n.parentNode;return n.parentNode.removeChild(n),t}function T(n,t,r){return n&&n.parentNode===t||r(t)?t.nextSibling||t.parentNode:t.firstChild||t.nextSibling||t.parentNode}v.paragraph={filter:"p",replacement:function(n){return"\n\n"+n+"\n\n"}},v.lineBreak={filter:"br",replacement:function(n,t,r){return r.br+"\n"}},v.heading={filter:["h1","h2","h3","h4","h5","h6"],replacement:function(t,r,e){var i=Number(r.nodeName.charAt(1));return"setext"===e.headingStyle&&i<3?"\n\n"+t+"\n"+n(1===i?"=":"-",t.length)+"\n\n":"\n\n"+n("#",i)+" "+t+"\n\n"}},v.blockquote={filter:"blockquote",replacement:function(n){return"\n\n"+(n=e(n).replace(/^/gm,"> "))+"\n\n"}},v.list={filter:["ul","ol"],replacement:function(n,t){var r=t.parentNode;return"LI"===r.nodeName&&r.lastElementChild===t?"\n"+n:"\n\n"+n+"\n\n"}},v.listItem={filter:"li",replacement:function(n,t,r){var i=r.bulletListMarker+" ",u=t.parentNode;if("OL"===u.nodeName){var f=u.getAttribute("start"),o=Array.prototype.indexOf.call(u.children,t);i=(f?Number(f)+o:o+1)+". "}var c=/\n$/.test(n);return i+(n=(n=e(n)+(c?"\n":"")).replace(/\n/gm,"\n"+" ".repeat(i.length)))+(t.nextSibling?"\n":"")}},v.indentedCodeBlock={filter:function(n,t){return"indented"===t.codeBlockStyle&&"PRE"===n.nodeName&&n.firstChild&&"CODE"===n.firstChild.nodeName},replacement:function(n,t){return"\n\n "+t.firstChild.textContent.replace(/\n/g,"\n ")+"\n\n"}},v.fencedCodeBlock={filter:function(n,t){return"fenced"===t.codeBlockStyle&&"PRE"===n.nodeName&&n.firstChild&&"CODE"===n.firstChild.nodeName},replacement:function(t,r,e){for(var i,u=((r.firstChild.getAttribute("class")||"").match(/language-(\S+)/)||[null,""])[1],f=r.firstChild.textContent,o=e.fence.charAt(0),c=3,a=new RegExp("^"+o+"{3,}","gm");i=a.exec(f);)i[0].length>=c&&(c=i[0].length+1);var l=n(o,c);return"\n\n"+l+u+"\n"+f.replace(/\n$/,"")+"\n"+l+"\n\n"}},v.horizontalRule={filter:"hr",replacement:function(n,t,r){return"\n\n"+r.hr+"\n\n"}},v.inlineLink={filter:function(n,t){return"inlined"===t.linkStyle&&"A"===n.nodeName&&n.getAttribute("href")},replacement:function(n,t){var r=E(t.getAttribute("href")),e=m(g(t.getAttribute("title")));return"["+n+"]("+r+(e?' "'+e+'"':"")+")"}},v.referenceLink={filter:function(n,t){return"referenced"===t.linkStyle&&"A"===n.nodeName&&n.getAttribute("href")},replacement:function(n,t,r){var e,i,u=E(t.getAttribute("href")),f=g(t.getAttribute("title"));switch(f&&(f=' "'+m(f)+'"'),r.linkReferenceStyle){case"collapsed":e="["+n+"][]",i="["+n+"]: "+u+f;break;case"shortcut":e="["+n+"]",i="["+n+"]: "+u+f;break;default:var o=this.references.length+1;e="["+n+"]["+o+"]",i="["+o+"]: "+u+f}return this.references.push(i),e},references:[],append:function(){var n="";return this.references.length&&(n="\n\n"+this.references.join("\n")+"\n\n",this.references=[]),n}},v.emphasis={filter:["em","i"],replacement:function(n,t,r){return n.trim()?r.emDelimiter+n+r.emDelimiter:""}},v.strong={filter:["strong","b"],replacement:function(n,t,r){return n.trim()?r.strongDelimiter+n+r.strongDelimiter:""}},v.code={filter:function(n){return"CODE"===n.nodeName&&!("PRE"===n.parentNode.nodeName&&!n.previousSibling&&!n.nextSibling)},replacement:function(n){if(!n)return"";n=n.replace(/\r?\n|\r/g," ");for(var t=/^`|^ .*?[^ ].* $|`$/.test(n)?" ":"",r="`",e=n.match(/`+/gm)||[];-1!==e.indexOf(r);)r+="`";return r+t+n+t+r}},v.image={filter:"img",replacement:function(n,t){var r=h(g(t.getAttribute("alt"))),e=E(t.getAttribute("src")||""),i=g(t.getAttribute("title")),u=i?' "'+m(i)+'"':"";return e?"":""}},d.prototype={add:function(n,t){this.array.unshift(t)},keep:function(n){this._keep.unshift({filter:n,replacement:this.keepReplacement})},remove:function(n){this._remove.unshift({filter:n,replacement:function(){return""}})},forNode:function(n){return n.isBlank?this.blankRule:(t=p(this.array,n,this.options))||(t=p(this._keep,n,this.options))||(t=p(this._remove,n,this.options))?t:this.defaultRule;var t},forEach:function(n){for(var t=0;t<this.array.length;t++)n(this.array[t],t)}};var O,D,w="undefined"!=typeof window?window:{},y=function(){var n=w.DOMParser,t=!1;try{(new n).parseFromString("","text/html")&&(t=!0)}catch(n){}return t}()?w.DOMParser:((O=function(){}).prototype.parseFromString=function(){var n=!1;try{document.implementation.createHTMLDocument("").open()}catch(t){w.ActiveXObject&&(n=!0)}return n}()?function(n){var t=new window.ActiveXObject("htmlfile");return t.designMode="on",t.open(),t.write(n),t.close(),t}:function(n){var t=document.implementation.createHTMLDocument("");return t.open(),t.write(n),t.close(),t},O);function I(n,t){var r;return function(n){var t=n.element,r=n.isBlock,e=n.isVoid,i=n.isPre||function(n){return"PRE"===n.nodeName};if(t.firstChild&&!i(t)){for(var u=null,f=!1,o=null,c=T(o,t,i);c!==t;){if(3===c.nodeType||4===c.nodeType){var a=c.data.replace(/[ \r\n\t]+/g," ");if(u&&!/ $/.test(u.data)||f||" "!==a[0]||(a=a.substr(1)),!a){c=R(c);continue}c.data=a,u=c}else{if(1!==c.nodeType){c=R(c);continue}r(c)||"BR"===c.nodeName?(u&&(u.data=u.data.replace(/ $/,"")),u=null,f=!1):e(c)||i(c)?(u=null,f=!0):u&&(f=!1)}var l=T(o,c,i);o=c,c=l}u&&(u.data=u.data.replace(/ $/,""),u.data||R(u))}}({element:r="string"==typeof n?(D=D||new y).parseFromString('<x-turndown id="turndown-root">'+n+"</x-turndown>","text/html").getElementById("turndown-root"):n.cloneNode(!0),isBlock:u,isVoid:o,isPre:t.preformattedCode?S:null}),r}function S(n){return"PRE"===n.nodeName||"CODE"===n.nodeName}function C(n,t){return n.isBlock=u(n),n.isCode="CODE"===n.nodeName||n.parentNode.isCode,n.isBlank=function(n){return!o(n)&&!function(n){return a(n,c)}(n)&&/^\s*$/i.test(n.textContent)&&!function(n){return l(n,f)}(n)&&!function(n){return l(n,c)}(n)}(n),n.flankingWhitespace=function(n,t){if(n.isBlock||t.preformattedCode&&n.isCode)return{leading:"",trailing:""};var r,e={leading:(r=n.textContent.match(/^(([ \t\r\n]*)(\s*))(?:(?=\S)[\s\S]*\S)?((\s*?)([ \t\r\n]*))$/))[1],leadingAscii:r[2],leadingNonAscii:r[3],trailing:r[4],trailingNonAscii:r[5],trailingAscii:r[6]};return e.leadingAscii&&N("left",n,t)&&(e.leading=e.leadingNonAscii),e.trailingAscii&&N("right",n,t)&&(e.trailing=e.trailingNonAscii),{leading:e.leading,trailing:e.trailing}}(n,t),n}function N(n,t,r){var e,i,f;return"left"===n?(e=t.previousSibling,i=/ $/):(e=t.nextSibling,i=/^ /),e&&(3===e.nodeType?f=i.test(e.nodeValue):r.preformattedCode&&"CODE"===e.nodeName?f=!1:1!==e.nodeType||u(e)||(f=i.test(e.textContent))),f}var H=Array.prototype.reduce;function L(n){if(!(this instanceof L))return new L(n);this.options=function(n){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var e in r)Object.prototype.hasOwnProperty.call(r,e)&&(n[e]=r[e])}return n}({},{rules:v,headingStyle:"setext",hr:"* * *",bulletListMarker:"*",codeBlockStyle:"indented",fence:"```",emDelimiter:"_",strongDelimiter:"**",linkStyle:"inlined",linkReferenceStyle:"full",br:" ",preformattedCode:!1,blankReplacement:function(n,t){return t.isBlock?"\n\n":""},keepReplacement:function(n,t){return t.isBlock?"\n\n"+t.outerHTML+"\n\n":t.outerHTML},defaultReplacement:function(n,t){return t.isBlock?"\n\n"+n+"\n\n":n}},n),this.rules=new d(this.options)}function M(n){var t=this;return H.call(n.childNodes,(function(n,r){var e="";return 3===(r=new C(r,t.options)).nodeType?e=r.isCode?r.nodeValue:t.escape(r.nodeValue):1===r.nodeType&&(e=$.call(t,r)),b(n,e)}),"")}function P(n){var t=this;return this.rules.forEach((function(r){"function"==typeof r.append&&(n=b(n,r.append(t.options)))})),n.replace(/^[\t\r\n]+/,"").replace(/[\t\r\n\s]+$/,"")}function $(n){var t=this.rules.forNode(n),r=M.call(this,n),e=n.flankingWhitespace;return(e.leading||e.trailing)&&(r=r.trim()),e.leading+t.replacement(r,n,this.options)+e.trailing}function b(n,e){var i=r(n),u=t(e),f=Math.max(n.length-i.length,e.length-u.length);return i+"\n\n".substring(0,f)+u}L.prototype={turndown:function(n){if(!function(n){return null!=n&&("string"==typeof n||n.nodeType&&(1===n.nodeType||9===n.nodeType||11===n.nodeType))}(n))throw new TypeError(n+" is not a string, or an element/document/fragment node.");if(""===n)return"";var t=M.call(this,new I(n,this.options));return P.call(this,t)},use:function(n){if(Array.isArray(n))for(var t=0;t<n.length;t++)this.use(n[t]);else{if("function"!=typeof n)throw new TypeError("plugin must be a Function or an Array of Functions");n(this)}return this},addRule:function(n,t){return this.rules.add(n,t),this},keep:function(n){return this.rules.keep(n),this},remove:function(n){return this.rules.remove(n),this},escape:function(n){return h(n)}};const B=new L,k=n=>{const t=B.turndown(n).replace(/^\#+\s+/gm,"").trim();return t?t.split(/[\n\r]+/gm):[]};export{k as c}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e,h as s,a as t}from"./p-ce75b047.js";import{f as o,z as i}from"./p-
|
|
1
|
+
import{r as e,h as s,a as t}from"./p-ce75b047.js";import{f as o,z as i}from"./p-9a417eeb.js";import{c as n}from"./p-b4b7f705.js";import{i as a}from"./p-ae393255.js";import{s as l}from"./p-96d77739.js";import"./p-0a377722.js";const h={pageHeader:{label:"Page Header (3XL) · 34px (2.125rem)",size:"3xl",tag:"h2",weight:900},secondaryPageHeader:{label:'Secondary Page Header (3XL) • 34px, 500 "Medium"',size:"3xl",tag:"h2",weight:500},header:{label:"Header (2XL) · 28px (1.75rem)",size:"2xl",tag:"h3",weight:700},descriptionHeader:{label:"Description Header (2XL) · 28px (1.75rem)",size:"2xl",tag:"h3",weight:700},title:{label:"Title (XL) • 22px (1.375rem)",size:"xl",tag:"h4",weight:600},boldSubheader:{label:"Bold Subheader (L) • 18px (1.125rem)",size:"l",tag:"h5",weight:700},semiBoldSubheader:{label:"Semi Bold Subheader (L / H4) • 18px (1.125rem)",size:"l",tag:"h5",weight:600},subheader:{label:"Subheader (L) • 18px (1.125rem)",size:"l",tag:"h5",weight:500},boldLabel:{label:"Bold Label (Base) • 14px (.875rem)",size:"base",tag:"span",weight:700},semiBoldLabel:{label:"Semi Bold Label (Base) • 14px (.875rem)",size:"base",tag:"span",weight:600},label:{label:"Label (Base) • 14px (.875rem)",size:"base",tag:"span",weight:500},body:{label:"Body (Base) • 14px (.875rem)",size:"base",tag:"span",weight:400},smallHeader:{label:"Small header (S) • 12px (.75rem)",size:"s",tag:"span",weight:600},caption:{label:"Caption (S) • 12px (.75rem)",size:"s",tag:"span",weight:400},hintText:{label:"Hint text (XS) • 10px (.625rem)",size:"xs",tag:"span",weight:400}},z=class{constructor(s){e(this,s),this.textColor="gray-1000",this.type="body",this.ready=!1}componentDidRender(){setTimeout((()=>{this.ready=!0}),100)}render(){const{size:e,tag:z,weight:r}=h.body,{size:x,tag:g,weight:m}=h[this.type],f=this.size||x||e,p=this.weight||m||r,d=g||z,b=a(this.textColor)?`var(--zonos-elements-${this.textColor})`:this.textColor;return s(t,{class:n(["zonos--elements",`zonos--text-size-${f}`,`zonos--text-weight-${p}`]),style:l({"--zonos--color":b,"--zonos--font-family":o(),"--zonos--font-size-2xl":i.appearance.fontSize2XL?`${i.appearance.fontSize2XL}px`:void 0,"--zonos--font-size-3xl":i.appearance.fontSize3XL?`${i.appearance.fontSize3XL}px`:void 0,"--zonos--font-size-base":i.appearance.fontSizeBase?`${i.appearance.fontSizeBase}px`:void 0,"--zonos--font-size-l":i.appearance.fontSizeL?`${i.appearance.fontSizeL}px`:void 0,"--zonos--font-size-s":i.appearance.fontSizeS?`${i.appearance.fontSizeS}px`:void 0,"--zonos--font-size-xl":i.appearance.fontSizeXL?`${i.appearance.fontSizeXL}px`:void 0,"--zonos--font-size-xs":i.appearance.fontSizeXS?`${i.appearance.fontSizeXS}px`:void 0})},(()=>{switch(d){case"h2":return s("h2",null,s("slot",null));case"h3":return s("h3",null,s("slot",null));case"h4":return s("h4",null,s("slot",null));case"h5":return s("h5",null,s("slot",null));default:return s("span",null,s("slot",null))}})())}};z.style=":host{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--zonos--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{color:var(--zonos--color)}:host(.zonos--text-size-3xl)>*,:host(.zonos--text-size-3xl){font-size:var(--zonos--font-size-3xl, var(--zonos-elements-font-size-3xl))}:host(.zonos--text-size-2xl)>*,:host(.zonos--text-size-2xl){font-size:var(--zonos--font-size-2xl, var(--zonos-elements-font-size-2xl));line-height:32px}:host(.zonos--text-size-xl)>*,:host(.zonos--text-size-xl){font-size:var(--zonos--font-size-xl, var(--zonos-elements-font-size-xl))}:host(.zonos--text-size-l)>*,:host(.zonos--text-size-l){font-size:var(--zonos--font-size-l, var(--zonos-elements-font-size-l))}:host(.zonos--text-size-base)>*,:host(.zonos--text-size-base){font-size:var(--zonos--font-size-base, var(--zonos-elements-font-size-base))}:host(.zonos--text-size-s)>*,:host(.zonos--text-size-s){font-size:var(--zonos--font-size-s, var(--zonos-elements-font-size-s))}:host(.zonos--text-size-xs)>*,:host(.zonos--text-size-xs){font-size:var(--zonos--font-size-xs, var(--zonos-elements-font-size-xs))}:host(.zonos--text-weight-900)>*,:host(.zonos--text-weight-900){font-weight:900}:host(.zonos--text-weight-700)>*,:host(.zonos--text-weight-700){font-weight:700}:host(.zonos--text-weight-600)>*,:host(.zonos--text-weight-600){font-weight:600}:host(.zonos--text-weight-500)>*,:host(.zonos--text-weight-500){font-weight:500}:host(.zonos--text-weight-400)>*,:host(.zonos--text-weight-400){font-weight:400}";export{z as zonos_text}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as o,h as e,a as t,g as s}from"./p-ce75b047.js";import{d as l}from"./p-4df08fc4.js";import{l as i,k as n,t as r,g as h,n as a,o as d,p as c,q as m,h as z,r as g}from"./p-41619f29.js";import{z as p,g as w,m as f}from"./p-701d9a7c.js";import{c as u}from"./p-b4b7f705.js";import{h as b,l as v}from"./p-41dd1cb8.js";import{g as x}from"./p-5883217a.js";import{l as y}from"./p-0a377722.js";const k=o=>{const e=null==o?void 0:o.replace("www.","").replace("https://","");return e&&new RegExp(e).test(window.location.href)},L=()=>{var o,e;const{productAddToCartElementSelector:t,productDescriptionElementSelector:s,productTitleElementSelector:l,restrictionBehavior:i}=p.helloSettings;l&&s||y("Hello could not check item restrictions - must provide title and description selectors.");const r=l&&n(l)&&document.querySelectorAll(l)||[],h=s&&n(s)&&document.querySelectorAll(s)||[];if(r.length!==h.length)return y("Hello could not check item restrictions - Title and description selectors do not match"),[];const a="RESTRICT_AND_BLOCK"===i,d=a&&t&&n(t)&&document.querySelectorAll(t)||[];a&&d.length!==h.length&&y('Hello could not disable "Add to cart" buttons - Title and add to cart selectors do not match');const c=[];for(let t=0;t<r.length;t++){const s=r[t],l=h[t];if(s&&l){const i={cartButtonNode:d[t]||null,description:(null===(o=l.textContent)||void 0===o?void 0:o.trim())||"",title:(null===(e=s.textContent)||void 0===e?void 0:e.trim())||""};c.push(i)}}return c},C=class{constructor(e){o(this,e),this.showPeekMessage=!1,this.zonosStoreHelloSettings=p.helloSettings,this.showDialog=!1,this.peekMessage="",this.initialUrl="",this.allRestrictedItems=[],this.allFoundProducts=[],this.productsOnPage=[],this.isHelloWidgetRendered=!1,this.isMobile=!1,this.getHelloPeekMessage=o=>{if(("productDetail"===p.currentHelloPage||"productList"===p.currentHelloPage)&&this.allRestrictedItems.length){const o=r("click to learn more");return`${r("productDetail"===p.currentHelloPage?"Restricted item":"Restricted items found")} - ${o}`}switch(p.currentHelloPage){case"cart":return r("Prepay duties and taxes at checkout");case"productList":case"productDetail":return r("See duty and tax thresholds");default:return r("Welcome to [storeName]",{storeName:o})}},this.enableShowPeekMessage=()=>{this.peekMessage&&(this.showPeekMessage=!0)},this.getNewItemRestrictions=async o=>"productDetail"!==p.currentHelloPage&&"productList"!==p.currentHelloPage||"DISABLED"===p.helloSettings.restrictionBehavior?[]:await(async o=>{if(!o.length)return[];const{selectedCountryCode:e}=i;if(!e)return v("Hello could not check item restrictions - No country code selected"),[];const t=o.map((o=>({description:o.description,name:o.title})));return(await(async({items:o,shipFrom:e,shipTo:t})=>{var s;const l={items:o,shipFrom:e,shipTo:t},{errors:i,json:n}=await b("/api/zonos-elements/check-item-restrictions",{body:l,method:"POST"});return i.length||!n?(v(`Error fetching item restrictions: ${null===(s=i.find(Boolean))||void 0===s?void 0:s.message}`),[]):n.filter(Boolean)})({items:t,shipFrom:"AD",shipTo:e})).map((o=>{var e;const s=(null===(e=t.filter((e=>e.description===o.itemDescription)).find(Boolean))||void 0===e?void 0:e.name)||"";return Object.assign(Object.assign({},o),{name:s})}))})(o),this.triggerShowPeekMessage=()=>{this.peekMessage=this.getHelloPeekMessage(p.organizationName);const{peekMessageBehavior:o,peekMessageDelay:e}=p.helloSettings;"ENABLED"===o&&setTimeout((()=>{this.enableShowPeekMessage(),this.allRestrictedItems.some((o=>this.productsOnPage.some((e=>e.description===o.itemDescription))))||setTimeout((()=>{this.showPeekMessage=!1}),3e3)}),1e3*e)},this.disableAddToCartButtons=()=>{this.productsOnPage.length&&this.productsOnPage.forEach((o=>{var e,t;this.allRestrictedItems.some((e=>e.itemDescription===o.description))?null===(e=o.cartButtonNode)||void 0===e||e.setAttribute("disabled","disabled"):null===(t=o.cartButtonNode)||void 0===t||t.removeAttribute("disabled")}))},this.handleItemRestrictions=async()=>{this.productsOnPage=L();const o=this.productsOnPage.filter((o=>!this.allFoundProducts.some((e=>e.title===o.title)))),e=await this.getNewItemRestrictions(o);this.allRestrictedItems.push(...e),this.allFoundProducts.push(...o),this.disableAddToCartButtons()},this.reloadHelloData=async()=>{await this.handleItemRestrictions(),this.triggerShowPeekMessage()},this.handleProductCountChange=l((()=>{const{productTitleElementSelector:o}=p.helloSettings;if(o){const o=L();if(this.allFoundProducts.length!==o.length&&window.location.href===this.initialUrl){if(!this.allFoundProducts.length)return;this.reloadHelloData()}}}),1e3),this.watchProductCountChange=()=>{var o;const e=new MutationObserver(this.handleProductCountChange);e.observe(document.body,{childList:!0,subtree:!0}),null===(o=this.observerWatcher)||void 0===o||o.push(e)},this.watchPriceChange=()=>{var o;const e=new MutationObserver((()=>{this.displayCurrency()}));e.observe(document.body,{attributes:!0,childList:!0,subtree:!0}),null===(o=this.observerWatcher)||void 0===o||o.push(e)},this.updateHelloOnPageChange=()=>{this.watchProductCountChange(),setInterval((()=>{if(window.location.href!==this.initialUrl){const o=this.initialUrl&&new URL(this.initialUrl);(o&&h(o.searchParams))!==i.selectedCountryCode&&(this.allFoundProducts=[],this.allRestrictedItems=[],this.productsOnPage=[]),this.initialUrl=window.location.href,p.currentHelloPage=(()=>{const{cartUrlPattern:o,homepageUrlPattern:e,productDetailUrlPattern:t,productListUrlPattern:s}=p.helloSettings;return k(o)?"cart":k(t)?"productDetail":k(s)?"productList":k(e)?"home":""})();const e=new URL(window.location.href);if(!h(e.searchParams))return void a(i.selectedCountryCode);this.reloadHelloData()}}),1e3)},this.changeShowDialog=o=>{this.showDialog=o},this.shouldAnimateLeftDesktop=()=>{const o=this.helloRef&&getComputedStyle(this.helloRef).position;if(this.helloRef&&"relative"===o)return x(this.helloRef)}}showDialogHandler(o){var e;if(o){const o=null===(e=this.helloElement)||void 0===e?void 0:e.parentElement;o&&o.parentElement===document.body&&(o.style.zIndex="2147483647",document.body.appendChild(o))}}async getCountryList(){return i.helloCountryList}componentWillLoad(){const o=setInterval((async()=>{this.helloRef&&p.loadedConfig&&(this.helloRef.setAttribute("data-zonos-hello-loaded",""),this.updateHelloOnPageChange(),this.watchPriceChange(),this.handleAppearanceSettingsOverrideChange(),clearInterval(o))}),100)}disconnectedCallback(){var o;null===(o=this.observerWatcher)||void 0===o||o.forEach((o=>o.disconnect()))}async displayCurrency(){"DISABLED"!==p.helloSettings.currencyBehavior&&(i.exchangeRate?d():y("Could not display currency. Exchange rate and format data is not available.","warn"))}async convertAndFormat(o){return c(o)}async convert(o){return m(o)}async format(o){return z({amount:o})}async openHelloDialog(o){this.changeShowDialog(o)}handleResize(){this.isMobile=window.innerWidth<=768}handleHelloWidgetInitializedState({countryCode:o,currencyCode:e}){var t,s;this.isHelloWidgetRendered||i.selectedCountryCode&&"function"==typeof p.helloSettings.onInitSuccess&&(this.isHelloWidgetRendered=!0,null===(s=(t=p.helloSettings).onInitSuccess)||void 0===s||s.call(t,{countryCode:o,currencyCode:e}))}getHelloLocation(){const o=this.mobileLocationOverride||p.helloSettings.mobileLocation,e=this.desktopLocationOverride||p.helloSettings.desktopLocation,t=this.isMobile;if(!0===t)return{isMobileWindow:t,isOnLeft:this.animateFromLeftOverride||(null==o?void 0:o.includes("LEFT")),isOnTop:null==o?void 0:o.includes("TOP"),shouldFloat:!!o};{const o=!!this.desktopLocationOverride||!p.helloSettings.anchorElementSelector&&!!e;return{isMobileWindow:t,isOnLeft:this.animateFromLeftOverride||(e?e.includes("LEFT"):this.shouldAnimateLeftDesktop()),isOnTop:null==e?void 0:e.includes("TOP"),shouldFloat:o}}}handleAppearanceSettingsOverrideChange(){var o;(null===(o=this.appearanceSettingsOverride)||void 0===o?void 0:o.theme)&&(this.appearanceSettingsOverride.theme=w(this.appearanceSettingsOverride.theme))}componentDidLoad(){this.isMobile=window.innerWidth<=768}render(){var o,s;if(null===(o=p.helloSettings.excludedUrlPatterns)||void 0===o?void 0:o.some((o=>o&&new RegExp(o).test(window.location.href))))return y("Hello is excluded on this url","warn"),null;const{selectedCountryCode:l,targetCurrency:n}=i,{isOnLeft:r,isOnTop:h,shouldFloat:a}=this.getHelloLocation(),d=f(p.appearance,this.appearanceSettingsOverride||null),{theme:c}=d,m=null===(s=this.allRestrictedItems)||void 0===s?void 0:s.filter((o=>this.productsOnPage.some((e=>e.description===o.itemDescription))));this.peekMessage=this.getHelloPeekMessage(p.organizationName);const z=g()&&!!l;z&&!this.isHelloWidgetRendered&&this.handleHelloWidgetInitializedState({countryCode:l,currencyCode:n});const w=null==(b=p.helloSettings.widgetSize)||!Number.isFinite(b)||b<=0?18:Math.min(64,Math.max(18,b));var b;return e(t,{class:"zonos--hello zonos--elements","data-theme":c,style:{"--zonos-elements-hello-widget-size":`${w}px`}},z&&e("div",{class:u(["zonos--hello-wrapper",a&&"zonos--hello-widget-float"])},e("button",{class:u(["zonos--hello-widget",this.showPeekMessage&&"zonos--hello-show-peek-message",this.mobileLocationOverride&&"zonos--hello-mobile-override",r&&"zonos--hello-widget-left zonos--hello-widget-animate-from-left",h&&"zonos--hello-widget-top",!!this.allRestrictedItems.length&&"zonos--hello-has-restrictions",a&&"zonos--hello-widget-float"]),onClick:()=>{this.changeShowDialog(!this.showDialog)},onMouseEnter:()=>this.enableShowPeekMessage(),onMouseLeave:()=>this.showPeekMessage=!1,ref:o=>o&&(this.helloRef=o),type:"button"},e("zonos-text",{class:"zonos--hello-message"},this.peekMessage),l&&e("div",{class:"zonos--hello-country-flag-wrapper"},e("zonos-country-flag",{class:"zonos--hello-country-flag",countryCode:l}))),e("div",{class:u(["zonos--hello-dialog-wrapper",this.mobileLocationOverride&&"zonos--hello-dialog-wrapper-mobile-override",r&&"zonos--hello-widget-left zonos--hello-widget-animate-from-left",h&&"zonos--hello-widget-top",a&&"zonos--hello-widget-float"]),style:{height:this.showDialog?"fit-content":"0px"}},e("zonos-hello-dialog",{animateFromLeftOverride:r,appearanceSettings:d,isOpen:this.showDialog,mobileLocationOverride:this.mobileLocationOverride,restrictedItems:m,setIsOpen:this.changeShowDialog}))))}get helloElement(){return s(this)}static get watchers(){return{showDialog:["showDialogHandler"],appearanceSettingsOverride:["handleAppearanceSettingsOverrideChange"]}}};C.style=":host{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--zonos--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:inline-block;--zonos-elements-hello-widget-size:18px;--zonos-elements-hello-bubble-padding:max(\n 6px,\n calc(var(--zonos-elements-hello-widget-size) * 0.22)\n );--zonos-elements-hello-bubble-size:calc(\n var(--zonos-elements-hello-widget-size) +\n var(--zonos-elements-hello-bubble-padding) * 2 + 2px\n )}:host .zonos--hello-wrapper{position:relative}:host .zonos--hello-wrapper .zonos--hello-dialog-wrapper-mobile-override{position:fixed;bottom:0;left:0;width:100vw;z-index:1001;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content}@media (max-width: 768px){:host .zonos--hello-wrapper .zonos--hello-dialog-wrapper{position:fixed;bottom:0;left:0;width:100vw;z-index:1001;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content}}@media screen and (min-width: 769px){:host .zonos--hello-wrapper .zonos--hello-dialog-wrapper.zonos--hello-widget-float{position:fixed;bottom:72px;right:32px;width:auto;height:auto;z-index:1001}:host .zonos--hello-wrapper .zonos--hello-dialog-wrapper.zonos--hello-widget-float.zonos--hello-widget-left{left:32px;right:auto}:host .zonos--hello-wrapper .zonos--hello-dialog-wrapper.zonos--hello-widget-float.zonos--hello-widget-top{bottom:auto;top:32px}}:host .zonos--hello-widget{-webkit-transition:all 0.7s cubic-bezier(0.31, -0.02, 0.06, 1.53);transition:all 0.7s cubic-bezier(0.31, -0.02, 0.06, 1.53);padding:var(--zonos-elements-hello-bubble-padding);border-radius:9999px;background:var(--zonos-elements-page-background);font-size:var(--zonos-elements-font-size-s);border:var(--zonos-elements-border);display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;cursor:pointer;-webkit-box-sizing:border-box;box-sizing:border-box;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;width:-webkit-fit-content;width:-moz-fit-content;width:fit-content;position:relative;z-index:1000}:host .zonos--hello-widget>.zonos--hello-message{-ms-flex-order:0;order:0;max-width:0;height:100%;white-space:nowrap;-webkit-transition:border 0.3s ease-in, all 0.7s cubic-bezier(0.31, -0.02, 0.06, 1.53);transition:border 0.3s ease-in, all 0.7s cubic-bezier(0.31, -0.02, 0.06, 1.53);overflow:hidden;color:var(--zonos-elements-text-color);position:absolute;background:var(--zonos-elements-page-background);display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;border-top-left-radius:calc(var(--zonos-elements-hello-bubble-size) / 2);border-bottom-left-radius:calc(var(--zonos-elements-hello-bubble-size) / 2);left:0;-webkit-transform:translateX(calc(-100% + var(--zonos-elements-hello-bubble-size) / 2));transform:translateX(calc(-100% + var(--zonos-elements-hello-bubble-size) / 2));width:-webkit-fit-content;width:-moz-fit-content;width:fit-content;border-top:var(--zonos-elements-border);border-bottom:var(--zonos-elements-border)}:host .zonos--hello-widget.zonos--hello-has-restrictions{background:var(--zonos-elements-red-100);border:1px solid var(--zonos-elements-red-200)}:host .zonos--hello-widget.zonos--hello-has-restrictions>.zonos--hello-message{background:var(--zonos-elements-red-100);color:var(--zonos-elements-red-800);font-weight:500}:host .zonos--hello-widget.zonos--hello-has-restrictions.zonos--hello-show-peek-message>.zonos--hello-message{border:1px solid var(--zonos-elements-red-200)}:host .zonos--hello-widget.zonos--hello-show-peek-message{max-width:100vw;width:100%}:host .zonos--hello-widget.zonos--hello-show-peek-message>.zonos--hello-message{max-width:100vw;padding:0 calc(var(--zonos-elements-hello-bubble-size) / 2);border:var(--zonos-elements-border)}:host .zonos--hello-widget.zonos--hello-show-peek-message:not(.zonos--hello-widget-animate-from-left)>.zonos--hello-message{border-right:none}:host .zonos--hello-widget.zonos--hello-show-peek-message.zonos--hello-widget-animate-from-left>.zonos--hello-message{padding-left:calc(var(--zonos-elements-hello-bubble-size) / 2);border-left:none}:host .zonos--hello-widget.zonos--hello-widget-animate-from-left>.zonos--hello-message{-ms-flex-order:1;order:1;-webkit-transform:translateX(calc(100% - var(--zonos-elements-hello-bubble-size) / 2));transform:translateX(calc(100% - var(--zonos-elements-hello-bubble-size) / 2));right:0;left:auto;border-top-left-radius:0;border-bottom-left-radius:0;border-top-right-radius:calc(var(--zonos-elements-hello-bubble-size) / 2);border-bottom-right-radius:calc(var(--zonos-elements-hello-bubble-size) / 2)}:host .zonos--hello-widget .zonos--hello-country-flag-wrapper{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center}:host .zonos--hello-widget .zonos--hello-country-flag-wrapper .zonos--hello-country-flag{height:18px;width:18px;position:relative;overflow:hidden;border-radius:30px;-webkit-box-shadow:var(--zonos-elements-v3-shadow-medium);box-shadow:var(--zonos-elements-v3-shadow-medium);z-index:10;justify-self:center;height:var(--zonos-elements-hello-widget-size);width:var(--zonos-elements-hello-widget-size)}:host .zonos--hello-widget.zonos--hello-widget-float{position:fixed;bottom:72px;right:32px}:host .zonos--hello-widget.zonos--hello-widget-float.zonos--hello-widget-left{left:32px;right:auto}:host .zonos--hello-widget.zonos--hello-widget-float.zonos--hello-widget-top{bottom:auto;top:32px}:host .zonos--hello-widget.zonos--hello-widget-float.zonos--hello-has-restrictions.zonos--hello-show-peek-message>.zonos--hello-message{border:none}:host .zonos--hello-widget.zonos--hello-widget-float>.zonos--hello-message{position:relative;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;border-radius:30px;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;top:0;bottom:0;left:0;-webkit-transform:translateX(0);transform:translateX(0);width:-webkit-fit-content;width:-moz-fit-content;width:fit-content;border:none}:host .zonos--hello-widget.zonos--hello-widget-float.zonos--hello-widget-animate-from-left>.zonos--hello-message{-webkit-transform:translateX(0);transform:translateX(0)}:host .zonos--hello-widget.zonos--hello-widget-float.zonos--hello-show-peek-message{width:-webkit-fit-content;width:-moz-fit-content;width:fit-content}:host .zonos--hello-widget.zonos--hello-widget-float.zonos--hello-show-peek-message.zonos--hello-widget-animate-from-left>.zonos--hello-message{padding-left:8px;padding-right:4px}:host .zonos--hello-widget.zonos--hello-widget-float.zonos--hello-show-peek-message>.zonos--hello-message{padding:0 var(--zonos-elements-radius-4);padding-right:6px;border:none}:host .zonos--hello-mobile-override.zonos--hello-widget.zonos--hello-widget-float{position:fixed;bottom:72px;right:32px}:host .zonos--hello-mobile-override.zonos--hello-widget.zonos--hello-widget-float.zonos--hello-widget-left{left:32px;right:auto}:host .zonos--hello-mobile-override.zonos--hello-widget.zonos--hello-widget-float.zonos--hello-widget-top{bottom:auto;top:32px}:host .zonos--hello-mobile-override.zonos--hello-widget.zonos--hello-widget-float.zonos--hello-has-restrictions.zonos--hello-show-peek-message>.zonos--hello-message{border:none}:host .zonos--hello-mobile-override.zonos--hello-widget.zonos--hello-widget-float>.zonos--hello-message{position:relative;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;border-radius:30px;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;top:0;bottom:0;left:0;-webkit-transform:translateX(0);transform:translateX(0);width:-webkit-fit-content;width:-moz-fit-content;width:fit-content;border:none}:host .zonos--hello-mobile-override.zonos--hello-widget.zonos--hello-widget-float.zonos--hello-widget-animate-from-left>.zonos--hello-message{-webkit-transform:translateX(0);transform:translateX(0)}:host .zonos--hello-mobile-override.zonos--hello-widget.zonos--hello-widget-float.zonos--hello-show-peek-message{width:-webkit-fit-content;width:-moz-fit-content;width:fit-content}:host .zonos--hello-mobile-override.zonos--hello-widget.zonos--hello-widget-float.zonos--hello-show-peek-message.zonos--hello-widget-animate-from-left>.zonos--hello-message{padding-left:8px;padding-right:4px}:host .zonos--hello-mobile-override.zonos--hello-widget.zonos--hello-widget-float.zonos--hello-show-peek-message>.zonos--hello-message{padding:0 var(--zonos-elements-radius-4);padding-right:6px;border:none}";export{C as zonos_hello}
|
|
1
|
+
import{r as o,h as e,a as t,g as s}from"./p-ce75b047.js";import{d as l}from"./p-7bdce9d4.js";import{l as i,k as n,t as r,g as h,n as a,o as d,p as c,q as m,h as z,r as g}from"./p-d7bda14d.js";import{z as p,g as w,m as f}from"./p-9a417eeb.js";import{c as b}from"./p-b4b7f705.js";import{h as u,l as v}from"./p-41dd1cb8.js";import{g as x}from"./p-5883217a.js";import{l as y}from"./p-0a377722.js";const k=o=>{const e=null==o?void 0:o.replace("www.","").replace("https://","");return e&&new RegExp(e).test(window.location.href)},L=()=>{var o,e;const{productAddToCartElementSelector:t,productDescriptionElementSelector:s,productTitleElementSelector:l,restrictionBehavior:i}=p.helloSettings;l&&s||y("Hello could not check item restrictions - must provide title and description selectors.");const r=l&&n(l)&&document.querySelectorAll(l)||[],h=s&&n(s)&&document.querySelectorAll(s)||[];if(r.length!==h.length)return y("Hello could not check item restrictions - Title and description selectors do not match"),[];const a="RESTRICT_AND_BLOCK"===i,d=a&&t&&n(t)&&document.querySelectorAll(t)||[];a&&d.length!==h.length&&y('Hello could not disable "Add to cart" buttons - Title and add to cart selectors do not match');const c=[];for(let t=0;t<r.length;t++){const s=r[t],l=h[t];if(s&&l){const i={cartButtonNode:d[t]||null,description:(null===(o=l.textContent)||void 0===o?void 0:o.trim())||"",title:(null===(e=s.textContent)||void 0===e?void 0:e.trim())||""};c.push(i)}}return c},C=class{constructor(e){o(this,e),this.showPeekMessage=!1,this.zonosStoreHelloSettings=p.helloSettings,this.showDialog=!1,this.peekMessage="",this.initialUrl="",this.allRestrictedItems=[],this.allFoundProducts=[],this.productsOnPage=[],this.isHelloWidgetRendered=!1,this.isMobile=!1,this.getHelloPeekMessage=o=>{if(("productDetail"===p.currentHelloPage||"productList"===p.currentHelloPage)&&this.allRestrictedItems.length){const o=r("click to learn more");return`${r("productDetail"===p.currentHelloPage?"Restricted item":"Restricted items found")} - ${o}`}switch(p.currentHelloPage){case"cart":return r("Prepay duties and taxes at checkout");case"productList":case"productDetail":return r("See duty and tax thresholds");default:return r("Welcome to [storeName]",{storeName:o})}},this.enableShowPeekMessage=()=>{this.peekMessage&&(this.showPeekMessage=!0)},this.getNewItemRestrictions=async o=>"productDetail"!==p.currentHelloPage&&"productList"!==p.currentHelloPage||"DISABLED"===p.helloSettings.restrictionBehavior?[]:await(async o=>{if(!o.length)return[];const{selectedCountryCode:e}=i;if(!e)return v("Hello could not check item restrictions - No country code selected"),[];const t=o.map((o=>({description:o.description,name:o.title})));return(await(async({items:o,shipFrom:e,shipTo:t})=>{var s;const l={items:o,shipFrom:e,shipTo:t},{errors:i,json:n}=await u("/api/zonos-elements/check-item-restrictions",{body:l,method:"POST"});return i.length||!n?(v(`Error fetching item restrictions: ${null===(s=i.find(Boolean))||void 0===s?void 0:s.message}`),[]):n.filter(Boolean)})({items:t,shipFrom:"AD",shipTo:e})).map((o=>{var e;const s=(null===(e=t.filter((e=>e.description===o.itemDescription)).find(Boolean))||void 0===e?void 0:e.name)||"";return Object.assign(Object.assign({},o),{name:s})}))})(o),this.triggerShowPeekMessage=()=>{this.peekMessage=this.getHelloPeekMessage(p.organizationName);const{peekMessageBehavior:o,peekMessageDelay:e}=p.helloSettings;"ENABLED"===o&&setTimeout((()=>{this.enableShowPeekMessage(),this.allRestrictedItems.some((o=>this.productsOnPage.some((e=>e.description===o.itemDescription))))||setTimeout((()=>{this.showPeekMessage=!1}),3e3)}),1e3*e)},this.disableAddToCartButtons=()=>{this.productsOnPage.length&&this.productsOnPage.forEach((o=>{var e,t;this.allRestrictedItems.some((e=>e.itemDescription===o.description))?null===(e=o.cartButtonNode)||void 0===e||e.setAttribute("disabled","disabled"):null===(t=o.cartButtonNode)||void 0===t||t.removeAttribute("disabled")}))},this.handleItemRestrictions=async()=>{this.productsOnPage=L();const o=this.productsOnPage.filter((o=>!this.allFoundProducts.some((e=>e.title===o.title)))),e=await this.getNewItemRestrictions(o);this.allRestrictedItems.push(...e),this.allFoundProducts.push(...o),this.disableAddToCartButtons()},this.reloadHelloData=async()=>{await this.handleItemRestrictions(),this.triggerShowPeekMessage()},this.handleProductCountChange=l((()=>{const{productTitleElementSelector:o}=p.helloSettings;if(o){const o=L();if(this.allFoundProducts.length!==o.length&&window.location.href===this.initialUrl){if(!this.allFoundProducts.length)return;this.reloadHelloData()}}}),1e3),this.watchProductCountChange=()=>{var o;const e=new MutationObserver(this.handleProductCountChange);e.observe(document.body,{childList:!0,subtree:!0}),null===(o=this.observerWatcher)||void 0===o||o.push(e)},this.watchPriceChange=()=>{var o;const e=new MutationObserver((()=>{this.displayCurrency()}));e.observe(document.body,{attributes:!0,childList:!0,subtree:!0}),null===(o=this.observerWatcher)||void 0===o||o.push(e)},this.updateHelloOnPageChange=()=>{this.watchProductCountChange(),setInterval((()=>{if(window.location.href!==this.initialUrl){const o=this.initialUrl&&new URL(this.initialUrl);(o&&h(o.searchParams))!==i.selectedCountryCode&&(this.allFoundProducts=[],this.allRestrictedItems=[],this.productsOnPage=[]),this.initialUrl=window.location.href,p.currentHelloPage=(()=>{const{cartUrlPattern:o,homepageUrlPattern:e,productDetailUrlPattern:t,productListUrlPattern:s}=p.helloSettings;return k(o)?"cart":k(t)?"productDetail":k(s)?"productList":k(e)?"home":""})();const e=new URL(window.location.href);if(!h(e.searchParams))return void a(i.selectedCountryCode);this.reloadHelloData()}}),1e3)},this.changeShowDialog=o=>{this.showDialog=o},this.shouldAnimateLeftDesktop=()=>{const o=this.helloRef&&getComputedStyle(this.helloRef).position;if(this.helloRef&&"relative"===o)return x(this.helloRef)}}showDialogHandler(o){var e;if(o){const o=null===(e=this.helloElement)||void 0===e?void 0:e.parentElement;o&&o.parentElement===document.body&&(o.style.zIndex="2147483647",document.body.appendChild(o))}}async getCountryList(){return i.helloCountryList}componentWillLoad(){const o=setInterval((async()=>{this.helloRef&&p.loadedConfig&&(this.helloRef.setAttribute("data-zonos-hello-loaded",""),this.updateHelloOnPageChange(),this.watchPriceChange(),this.handleAppearanceSettingsOverrideChange(),clearInterval(o))}),100)}disconnectedCallback(){var o;null===(o=this.observerWatcher)||void 0===o||o.forEach((o=>o.disconnect()))}async displayCurrency(){"DISABLED"!==p.helloSettings.currencyBehavior&&(i.exchangeRate?d():y("Could not display currency. Exchange rate and format data is not available.","warn"))}async convertAndFormat(o){return c(o)}async convert(o){return m(o)}async format(o){return z({amount:o})}async openHelloDialog(o){this.changeShowDialog(o)}handleResize(){this.isMobile=window.innerWidth<=768}handleHelloWidgetInitializedState({countryCode:o,currencyCode:e}){var t,s;this.isHelloWidgetRendered||i.selectedCountryCode&&"function"==typeof p.helloSettings.onInitSuccess&&(this.isHelloWidgetRendered=!0,null===(s=(t=p.helloSettings).onInitSuccess)||void 0===s||s.call(t,{countryCode:o,currencyCode:e}))}getHelloLocation(){const o=this.mobileLocationOverride||p.helloSettings.mobileLocation,e=this.desktopLocationOverride||p.helloSettings.desktopLocation,t=this.isMobile;if(!0===t)return{isMobileWindow:t,isOnLeft:this.animateFromLeftOverride||(null==o?void 0:o.includes("LEFT")),isOnTop:null==o?void 0:o.includes("TOP"),shouldFloat:!!o};{const o=!!this.desktopLocationOverride||!p.helloSettings.anchorElementSelector&&!!e;return{isMobileWindow:t,isOnLeft:this.animateFromLeftOverride||(e?e.includes("LEFT"):this.shouldAnimateLeftDesktop()),isOnTop:null==e?void 0:e.includes("TOP"),shouldFloat:o}}}handleAppearanceSettingsOverrideChange(){var o;(null===(o=this.appearanceSettingsOverride)||void 0===o?void 0:o.theme)&&(this.appearanceSettingsOverride.theme=w(this.appearanceSettingsOverride.theme))}componentDidLoad(){this.isMobile=window.innerWidth<=768}render(){var o,s;if(null===(o=p.helloSettings.excludedUrlPatterns)||void 0===o?void 0:o.some((o=>o&&new RegExp(o).test(window.location.href))))return y("Hello is excluded on this url","warn"),null;const{selectedCountryCode:l,targetCurrency:n}=i,{isOnLeft:r,isOnTop:h,shouldFloat:a}=this.getHelloLocation(),d=f(p.appearance,this.appearanceSettingsOverride||null),{theme:c}=d,m=null===(s=this.allRestrictedItems)||void 0===s?void 0:s.filter((o=>this.productsOnPage.some((e=>e.description===o.itemDescription))));this.peekMessage=this.getHelloPeekMessage(p.organizationName);const z=g()&&!!l;z&&!this.isHelloWidgetRendered&&this.handleHelloWidgetInitializedState({countryCode:l,currencyCode:n});const w=null==(u=p.helloSettings.widgetSize)||!Number.isFinite(u)||u<=0?18:Math.min(64,Math.max(18,u));var u;return e(t,{class:"zonos--hello zonos--elements","data-theme":c,style:{"--zonos-elements-hello-widget-size":`${w}px`}},z&&e("div",{class:b(["zonos--hello-wrapper",a&&"zonos--hello-widget-float"])},e("button",{class:b(["zonos--hello-widget",this.showPeekMessage&&"zonos--hello-show-peek-message",this.mobileLocationOverride&&"zonos--hello-mobile-override",r&&"zonos--hello-widget-left zonos--hello-widget-animate-from-left",h&&"zonos--hello-widget-top",!!this.allRestrictedItems.length&&"zonos--hello-has-restrictions",a&&"zonos--hello-widget-float"]),onClick:()=>{this.changeShowDialog(!this.showDialog)},onMouseEnter:()=>this.enableShowPeekMessage(),onMouseLeave:()=>this.showPeekMessage=!1,ref:o=>o&&(this.helloRef=o),type:"button"},e("zonos-text",{class:"zonos--hello-message"},this.peekMessage),l&&e("div",{class:"zonos--hello-country-flag-wrapper"},e("zonos-country-flag",{class:"zonos--hello-country-flag",countryCode:l}))),e("div",{class:b(["zonos--hello-dialog-wrapper",this.mobileLocationOverride&&"zonos--hello-dialog-wrapper-mobile-override",r&&"zonos--hello-widget-left zonos--hello-widget-animate-from-left",h&&"zonos--hello-widget-top",a&&"zonos--hello-widget-float"]),style:{height:this.showDialog?"fit-content":"0px"}},e("zonos-hello-dialog",{animateFromLeftOverride:r,appearanceSettings:d,isOpen:this.showDialog,mobileLocationOverride:this.mobileLocationOverride,restrictedItems:m,setIsOpen:this.changeShowDialog}))))}get helloElement(){return s(this)}static get watchers(){return{showDialog:["showDialogHandler"],appearanceSettingsOverride:["handleAppearanceSettingsOverrideChange"]}}};C.style=":host{font-family:var(--zonos--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--zonos--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:inline-block;--zonos-elements-hello-widget-size:18px;--zonos-elements-hello-bubble-padding:max(\n 6px,\n calc(var(--zonos-elements-hello-widget-size) * 0.22)\n );--zonos-elements-hello-bubble-size:calc(\n var(--zonos-elements-hello-widget-size) +\n var(--zonos-elements-hello-bubble-padding) * 2 + 2px\n )}:host .zonos--hello-wrapper{position:relative}:host .zonos--hello-wrapper .zonos--hello-dialog-wrapper-mobile-override{position:fixed;bottom:0;left:0;width:100vw;z-index:1001;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content}@media (max-width: 768px){:host .zonos--hello-wrapper .zonos--hello-dialog-wrapper{position:fixed;bottom:0;left:0;width:100vw;z-index:1001;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content}}@media screen and (min-width: 769px){:host .zonos--hello-wrapper .zonos--hello-dialog-wrapper.zonos--hello-widget-float{position:fixed;bottom:72px;right:32px;width:auto;height:auto;z-index:1001}:host .zonos--hello-wrapper .zonos--hello-dialog-wrapper.zonos--hello-widget-float.zonos--hello-widget-left{left:32px;right:auto}:host .zonos--hello-wrapper .zonos--hello-dialog-wrapper.zonos--hello-widget-float.zonos--hello-widget-top{bottom:auto;top:32px}}:host .zonos--hello-widget{-webkit-transition:all 0.7s cubic-bezier(0.31, -0.02, 0.06, 1.53);transition:all 0.7s cubic-bezier(0.31, -0.02, 0.06, 1.53);padding:var(--zonos-elements-hello-bubble-padding);border-radius:9999px;background:var(--zonos-elements-page-background);font-size:var(--zonos-elements-font-size-s);border:var(--zonos-elements-border);display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;cursor:pointer;-webkit-box-sizing:border-box;box-sizing:border-box;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;width:-webkit-fit-content;width:-moz-fit-content;width:fit-content;position:relative;z-index:1000}:host .zonos--hello-widget>.zonos--hello-message{-ms-flex-order:0;order:0;max-width:0;height:100%;white-space:nowrap;-webkit-transition:border 0.3s ease-in, all 0.7s cubic-bezier(0.31, -0.02, 0.06, 1.53);transition:border 0.3s ease-in, all 0.7s cubic-bezier(0.31, -0.02, 0.06, 1.53);overflow:hidden;color:var(--zonos-elements-text-color);position:absolute;background:var(--zonos-elements-page-background);display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;border-top-left-radius:calc(var(--zonos-elements-hello-bubble-size) / 2);border-bottom-left-radius:calc(var(--zonos-elements-hello-bubble-size) / 2);left:0;-webkit-transform:translateX(calc(-100% + var(--zonos-elements-hello-bubble-size) / 2));transform:translateX(calc(-100% + var(--zonos-elements-hello-bubble-size) / 2));width:-webkit-fit-content;width:-moz-fit-content;width:fit-content;border-top:var(--zonos-elements-border);border-bottom:var(--zonos-elements-border)}:host .zonos--hello-widget.zonos--hello-has-restrictions{background:var(--zonos-elements-red-100);border:1px solid var(--zonos-elements-red-200)}:host .zonos--hello-widget.zonos--hello-has-restrictions>.zonos--hello-message{background:var(--zonos-elements-red-100);color:var(--zonos-elements-red-800);font-weight:500}:host .zonos--hello-widget.zonos--hello-has-restrictions.zonos--hello-show-peek-message>.zonos--hello-message{border:1px solid var(--zonos-elements-red-200)}:host .zonos--hello-widget.zonos--hello-show-peek-message{max-width:100vw;width:100%}:host .zonos--hello-widget.zonos--hello-show-peek-message>.zonos--hello-message{max-width:100vw;padding:0 calc(var(--zonos-elements-hello-bubble-size) / 2);border:var(--zonos-elements-border)}:host .zonos--hello-widget.zonos--hello-show-peek-message:not(.zonos--hello-widget-animate-from-left)>.zonos--hello-message{border-right:none}:host .zonos--hello-widget.zonos--hello-show-peek-message.zonos--hello-widget-animate-from-left>.zonos--hello-message{padding-left:calc(var(--zonos-elements-hello-bubble-size) / 2);border-left:none}:host .zonos--hello-widget.zonos--hello-widget-animate-from-left>.zonos--hello-message{-ms-flex-order:1;order:1;-webkit-transform:translateX(calc(100% - var(--zonos-elements-hello-bubble-size) / 2));transform:translateX(calc(100% - var(--zonos-elements-hello-bubble-size) / 2));right:0;left:auto;border-top-left-radius:0;border-bottom-left-radius:0;border-top-right-radius:calc(var(--zonos-elements-hello-bubble-size) / 2);border-bottom-right-radius:calc(var(--zonos-elements-hello-bubble-size) / 2)}:host .zonos--hello-widget .zonos--hello-country-flag-wrapper{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center}:host .zonos--hello-widget .zonos--hello-country-flag-wrapper .zonos--hello-country-flag{height:18px;width:18px;position:relative;overflow:hidden;border-radius:30px;-webkit-box-shadow:var(--zonos-elements-v3-shadow-medium);box-shadow:var(--zonos-elements-v3-shadow-medium);z-index:10;justify-self:center;height:var(--zonos-elements-hello-widget-size);width:var(--zonos-elements-hello-widget-size)}:host .zonos--hello-widget.zonos--hello-widget-float{position:fixed;bottom:72px;right:32px}:host .zonos--hello-widget.zonos--hello-widget-float.zonos--hello-widget-left{left:32px;right:auto}:host .zonos--hello-widget.zonos--hello-widget-float.zonos--hello-widget-top{bottom:auto;top:32px}:host .zonos--hello-widget.zonos--hello-widget-float.zonos--hello-has-restrictions.zonos--hello-show-peek-message>.zonos--hello-message{border:none}:host .zonos--hello-widget.zonos--hello-widget-float>.zonos--hello-message{position:relative;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;border-radius:30px;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;top:0;bottom:0;left:0;-webkit-transform:translateX(0);transform:translateX(0);width:-webkit-fit-content;width:-moz-fit-content;width:fit-content;border:none}:host .zonos--hello-widget.zonos--hello-widget-float.zonos--hello-widget-animate-from-left>.zonos--hello-message{-webkit-transform:translateX(0);transform:translateX(0)}:host .zonos--hello-widget.zonos--hello-widget-float.zonos--hello-show-peek-message{width:-webkit-fit-content;width:-moz-fit-content;width:fit-content}:host .zonos--hello-widget.zonos--hello-widget-float.zonos--hello-show-peek-message.zonos--hello-widget-animate-from-left>.zonos--hello-message{padding-left:8px;padding-right:4px}:host .zonos--hello-widget.zonos--hello-widget-float.zonos--hello-show-peek-message>.zonos--hello-message{padding:0 var(--zonos-elements-radius-4);padding-right:6px;border:none}:host .zonos--hello-mobile-override.zonos--hello-widget.zonos--hello-widget-float{position:fixed;bottom:72px;right:32px}:host .zonos--hello-mobile-override.zonos--hello-widget.zonos--hello-widget-float.zonos--hello-widget-left{left:32px;right:auto}:host .zonos--hello-mobile-override.zonos--hello-widget.zonos--hello-widget-float.zonos--hello-widget-top{bottom:auto;top:32px}:host .zonos--hello-mobile-override.zonos--hello-widget.zonos--hello-widget-float.zonos--hello-has-restrictions.zonos--hello-show-peek-message>.zonos--hello-message{border:none}:host .zonos--hello-mobile-override.zonos--hello-widget.zonos--hello-widget-float>.zonos--hello-message{position:relative;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;border-radius:30px;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;top:0;bottom:0;left:0;-webkit-transform:translateX(0);transform:translateX(0);width:-webkit-fit-content;width:-moz-fit-content;width:fit-content;border:none}:host .zonos--hello-mobile-override.zonos--hello-widget.zonos--hello-widget-float.zonos--hello-widget-animate-from-left>.zonos--hello-message{-webkit-transform:translateX(0);transform:translateX(0)}:host .zonos--hello-mobile-override.zonos--hello-widget.zonos--hello-widget-float.zonos--hello-show-peek-message{width:-webkit-fit-content;width:-moz-fit-content;width:fit-content}:host .zonos--hello-mobile-override.zonos--hello-widget.zonos--hello-widget-float.zonos--hello-show-peek-message.zonos--hello-widget-animate-from-left>.zonos--hello-message{padding-left:8px;padding-right:4px}:host .zonos--hello-mobile-override.zonos--hello-widget.zonos--hello-widget-float.zonos--hello-show-peek-message>.zonos--hello-message{padding:0 var(--zonos-elements-radius-4);padding-right:6px;border:none}";export{C as zonos_hello}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
System.register(["./p-
|
|
1
|
+
System.register(["./p-dab78981.system.js"],(function(t){"use strict";var e;return{setters:[function(t){e=t.t}],execute:function(){var n=t("i",(function(t){var n=t.backgroundColor1,r=t.backgroundColor2;var s=e.readability(n,r);return s>2.5}))}}}));
|