@zonos/elements 1.3.171 → 1.3.173

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.
Files changed (133) hide show
  1. package/dist/cjs/{CheckoutConfig-f5e68e14.js → CheckoutConfig-c5943bbf.js} +1 -1
  2. package/dist/cjs/{cart-36799bbe.js → cart-d9052930.js} +21 -8
  3. package/dist/cjs/{handleFetch-7b7f9f7c.js → handleFetch-ff25db40.js} +10 -6
  4. package/dist/cjs/index.cjs.js +9 -9
  5. package/dist/cjs/loader.cjs.js +1 -1
  6. package/dist/cjs/{paypal-3eae38bd.js → paypal-31477331.js} +6 -2
  7. package/dist/cjs/zonos-address_7.cjs.entry.js +61 -19
  8. package/dist/cjs/zonos-cart-items_13.cjs.entry.js +20 -12
  9. package/dist/cjs/zonos-checkout.cjs.entry.js +106 -36
  10. package/dist/cjs/zonos-controller.cjs.entry.js +2 -2
  11. package/dist/cjs/zonos-country-flag.cjs.entry.js +2 -2
  12. package/dist/cjs/zonos-country-select_4.cjs.entry.js +2 -2
  13. package/dist/cjs/zonos-elements.cjs.js +1 -1
  14. package/dist/cjs/zonos-empty-state-payment_4.cjs.entry.js +20 -4
  15. package/dist/cjs/zonos-hello-dialog.cjs.entry.js +2 -2
  16. package/dist/cjs/zonos-hello.cjs.entry.js +2 -2
  17. package/dist/cjs/zonos-language-select_2.cjs.entry.js +2 -2
  18. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-finish/zonos-checkout-finish.js +10 -6
  19. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout.js +114 -37
  20. package/dist/collection/components/checkout/zonos-checkout/zonos-customer-info/zonos-customer-info.js +10 -6
  21. package/dist/collection/components/store/checkout/cart.js +5 -0
  22. package/dist/collection/components/store/checkout/paypal.js +5 -0
  23. package/dist/collection/components/store/checkout/stripe.js +12 -7
  24. package/dist/collection/components/stripe/zonos-address/zonos-address.js +37 -16
  25. package/dist/collection/components/stripe/zonos-link-authentication/zonos-link-authentication.js +27 -4
  26. package/dist/collection/components/stripe/zonos-payment/zonos-payment.js +22 -2
  27. package/dist/collection/components/utils/api/trackConversionEvent.js +1 -0
  28. package/dist/collection/components/utils/handleFetch.js +9 -6
  29. package/dist/collection/components/utils/logging/getAdditionalLogMetadata.js +1 -0
  30. package/dist/collection/styles/stripe/defaultVariable.js +2 -0
  31. package/dist/collection/types/generated/graphql.frontend.types.js +9 -0
  32. package/dist/collection/types/generated/graphql.internal.types.js +16 -0
  33. package/dist/esm/{CheckoutConfig-2994efd9.js → CheckoutConfig-75af3742.js} +1 -1
  34. package/dist/esm/{cart-b2e57589.js → cart-fff4f4a4.js} +21 -8
  35. package/dist/esm/{handleFetch-8d72c8cd.js → handleFetch-0109fb78.js} +10 -6
  36. package/dist/esm/index.js +10 -10
  37. package/dist/esm/loader.js +1 -1
  38. package/dist/esm/{paypal-38da5d52.js → paypal-087fbd16.js} +6 -2
  39. package/dist/esm/zonos-address_7.entry.js +61 -19
  40. package/dist/esm/zonos-cart-items_13.entry.js +20 -12
  41. package/dist/esm/zonos-checkout.entry.js +106 -36
  42. package/dist/esm/zonos-controller.entry.js +2 -2
  43. package/dist/esm/zonos-country-flag.entry.js +2 -2
  44. package/dist/esm/zonos-country-select_4.entry.js +2 -2
  45. package/dist/esm/zonos-elements.js +1 -1
  46. package/dist/esm/zonos-empty-state-payment_4.entry.js +20 -4
  47. package/dist/esm/zonos-hello-dialog.entry.js +2 -2
  48. package/dist/esm/zonos-hello.entry.js +2 -2
  49. package/dist/esm/zonos-language-select_2.entry.js +2 -2
  50. package/dist/esm-es5/{CheckoutConfig-2994efd9.js → CheckoutConfig-75af3742.js} +1 -1
  51. package/dist/esm-es5/{cart-b2e57589.js → cart-fff4f4a4.js} +1 -1
  52. package/dist/esm-es5/handleFetch-0109fb78.js +1 -0
  53. package/dist/esm-es5/index.js +1 -1
  54. package/dist/esm-es5/loader.js +1 -1
  55. package/dist/esm-es5/{paypal-38da5d52.js → paypal-087fbd16.js} +2 -2
  56. package/dist/esm-es5/zonos-address_7.entry.js +1 -1
  57. package/dist/esm-es5/zonos-cart-items_13.entry.js +1 -1
  58. package/dist/esm-es5/zonos-checkout.entry.js +1 -1
  59. package/dist/esm-es5/zonos-controller.entry.js +1 -1
  60. package/dist/esm-es5/zonos-country-flag.entry.js +1 -1
  61. package/dist/esm-es5/zonos-country-select_4.entry.js +1 -1
  62. package/dist/esm-es5/zonos-elements.js +1 -1
  63. package/dist/esm-es5/zonos-empty-state-payment_4.entry.js +1 -1
  64. package/dist/esm-es5/zonos-hello-dialog.entry.js +1 -1
  65. package/dist/esm-es5/zonos-hello.entry.js +1 -1
  66. package/dist/esm-es5/zonos-language-select_2.entry.js +1 -1
  67. package/dist/scripts/index.d.ts +26 -6
  68. package/dist/scripts/index.js +1 -1
  69. package/dist/scripts/loadZonos.js +1 -1
  70. package/dist/scripts/zonos.js +1 -1
  71. package/dist/types/components/checkout/zonos-checkout/zonos-checkout.d.ts +17 -3
  72. package/dist/types/components/checkout/zonos-checkout/zonos-customer-info/zonos-customer-info.d.ts +1 -1
  73. package/dist/types/components/store/checkout/cart.d.ts +4 -0
  74. package/dist/types/components/store/checkout/stripe.d.ts +10 -1
  75. package/dist/types/components/stripe/zonos-address/zonos-address.d.ts +6 -2
  76. package/dist/types/components/stripe/zonos-link-authentication/zonos-link-authentication.d.ts +1 -1
  77. package/dist/types/components/stripe/zonos-payment/zonos-payment.d.ts +3 -0
  78. package/dist/types/components/utils/logging/getAdditionalLogMetadata.d.ts +1 -0
  79. package/dist/types/components.d.ts +8 -6
  80. package/dist/types/types/ConversionEvent.d.ts +2 -1
  81. package/dist/types/types/checkout/CheckoutConfig.d.ts +1 -0
  82. package/dist/types/types/checkout/api/CheckoutSession.d.ts +8 -0
  83. package/dist/types/types/generated/graphql.frontend.types.d.ts +92 -0
  84. package/dist/types/types/generated/graphql.frontend.types.ts +106 -0
  85. package/dist/types/types/generated/graphql.internal.types.d.ts +124 -0
  86. package/dist/types/types/generated/graphql.internal.types.ts +154 -0
  87. package/dist/zonos-elements/assets/RemoveIcon.svg +1 -1
  88. package/dist/zonos-elements/index.esm.js +1 -1
  89. package/dist/zonos-elements/{p-0bfca3a9.system.entry.js → p-0078362c.system.entry.js} +1 -1
  90. package/dist/zonos-elements/p-033817e3.system.entry.js +1 -0
  91. package/dist/zonos-elements/p-04c38987.system.js +1 -0
  92. package/dist/zonos-elements/{p-cb52cfdf.entry.js → p-0db19b02.entry.js} +1 -1
  93. package/dist/zonos-elements/p-1b5a2714.system.entry.js +1 -0
  94. package/dist/zonos-elements/{p-1edbfb1f.system.entry.js → p-1be7b435.system.entry.js} +1 -1
  95. package/dist/zonos-elements/{p-47f79a6d.js → p-1c488ecf.js} +1 -1
  96. package/dist/zonos-elements/{p-c5c2976f.system.js → p-2ebb4fa7.system.js} +1 -1
  97. package/dist/zonos-elements/{p-1a20922f.system.entry.js → p-31ce9143.system.entry.js} +1 -1
  98. package/dist/zonos-elements/{p-a3888f1d.system.js → p-38f6f6fd.system.js} +1 -1
  99. package/dist/zonos-elements/{p-b0c39400.entry.js → p-407a96d2.entry.js} +1 -1
  100. package/dist/zonos-elements/p-427c2766.entry.js +1 -0
  101. package/dist/zonos-elements/p-46f6e5e9.system.js +1 -1
  102. package/dist/zonos-elements/{p-0def1397.system.entry.js → p-514431e9.system.entry.js} +1 -1
  103. package/dist/zonos-elements/p-5275b7ca.system.entry.js +1 -0
  104. package/dist/zonos-elements/p-5edc11be.system.entry.js +1 -0
  105. package/dist/zonos-elements/{p-461ca324.entry.js → p-67ca7373.entry.js} +1 -1
  106. package/dist/zonos-elements/{p-864c7c7d.entry.js → p-73a7b89b.entry.js} +1 -1
  107. package/dist/zonos-elements/{p-ecd4ec15.system.js → p-759a654a.system.js} +1 -1
  108. package/dist/zonos-elements/{p-bfa028a2.entry.js → p-7862da71.entry.js} +1 -1
  109. package/dist/zonos-elements/p-78b81404.system.js +17 -0
  110. package/dist/zonos-elements/p-839448c3.js +1 -0
  111. package/dist/zonos-elements/p-8b33c3b7.entry.js +1 -0
  112. package/dist/zonos-elements/{p-56a8b1f6.system.entry.js → p-a83370c6.system.entry.js} +1 -1
  113. package/dist/zonos-elements/{p-ff1c6d9a.entry.js → p-a9d7746a.entry.js} +1 -1
  114. package/dist/zonos-elements/{p-c82f488b.system.entry.js → p-ada6e691.system.entry.js} +1 -1
  115. package/dist/zonos-elements/{p-dd0259f4.js → p-bfd6e156.js} +1 -1
  116. package/dist/zonos-elements/p-cbd2bd33.js +17 -0
  117. package/dist/zonos-elements/p-ef9fdf45.entry.js +1 -0
  118. package/dist/zonos-elements/p-f6c0da8b.entry.js +1 -0
  119. package/dist/zonos-elements/zonos-elements.esm.js +1 -1
  120. package/package.json +1 -1
  121. package/dist/esm-es5/handleFetch-8d72c8cd.js +0 -1
  122. package/dist/zonos-elements/p-00ad3c73.entry.js +0 -1
  123. package/dist/zonos-elements/p-173d1fcd.system.entry.js +0 -1
  124. package/dist/zonos-elements/p-48173901.js +0 -17
  125. package/dist/zonos-elements/p-53cb8867.system.entry.js +0 -1
  126. package/dist/zonos-elements/p-56758218.system.entry.js +0 -1
  127. package/dist/zonos-elements/p-71539c8a.js +0 -1
  128. package/dist/zonos-elements/p-9261869c.system.js +0 -1
  129. package/dist/zonos-elements/p-934164df.entry.js +0 -1
  130. package/dist/zonos-elements/p-9f9e4f74.entry.js +0 -1
  131. package/dist/zonos-elements/p-bf113a46.system.js +0 -17
  132. package/dist/zonos-elements/p-e09cea9c.entry.js +0 -1
  133. package/dist/zonos-elements/p-fd352222.system.entry.js +0 -1
@@ -3,17 +3,17 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  const index = require('./index-2f90486e.js');
6
- const cart = require('./cart-36799bbe.js');
7
- const paypal = require('./paypal-3eae38bd.js');
6
+ const cart = require('./cart-d9052930.js');
7
+ const paypal = require('./paypal-31477331.js');
8
8
  const zonosStore = require('./zonosStore-3812b318.js');
9
- const handleFetch = require('./handleFetch-7b7f9f7c.js');
9
+ const handleFetch = require('./handleFetch-ff25db40.js');
10
10
  const isCheckoutMobile = require('./isCheckoutMobile-f491ca7c.js');
11
11
  const classes = require('./classes-b7918f56.js');
12
12
  const createCustomEvent = require('./createCustomEvent-7b6fad95.js');
13
13
  const getBorderRadius = require('./getBorderRadius-94ef609c.js');
14
14
  const isDarkColor = require('./isDarkColor-ec4a4e7d.js');
15
15
  const styles = require('./styles-d1e64fb9.js');
16
- const CheckoutConfig = require('./CheckoutConfig-f5e68e14.js');
16
+ const CheckoutConfig = require('./CheckoutConfig-c5943bbf.js');
17
17
  const RemoveIcon = require('./RemoveIcon-081ac073.js');
18
18
 
19
19
  /**
@@ -399,13 +399,30 @@ const ZonosCheckout = class {
399
399
  settlementAmount: total,
400
400
  };
401
401
  };
402
+ this.getDefaultAddress = () => {
403
+ // If checkout customer is authenticated, use the address from the customer profile
404
+ if (this.defaultCustomerProfileAddress.length) {
405
+ return this.defaultCustomerProfileAddress;
406
+ }
407
+ // If default address is provided directly from the component, use it
408
+ if (Array.isArray(this.defaultAddress) && this.defaultAddress.length) {
409
+ return this.defaultAddress;
410
+ }
411
+ if (!Array.isArray(this.defaultAddress) &&
412
+ typeof this.defaultAddress === 'object') {
413
+ return [this.defaultAddress];
414
+ }
415
+ return this.defaultAddressParams;
416
+ };
402
417
  this.appearanceSettingsOverride = undefined;
403
418
  this.preview = false;
404
419
  this.mobile = false;
405
420
  this.overrideStagingMode = undefined;
406
- this.defaultAddress = null;
421
+ this.defaultAddress = [];
407
422
  this.forceDialogOpen = false;
408
- this.defaultAddressParams = null;
423
+ this.defaultAddressParams = [];
424
+ this.defaultCustomerProfileAddress = [];
425
+ this.customerProfile = null;
409
426
  this.open = this.forceDialogOpen;
410
427
  this.stripe = window.Zonos.stripe;
411
428
  this.submitLoading = false;
@@ -422,6 +439,7 @@ const ZonosCheckout = class {
422
439
  this.inventoryCheckErrorMessage = null;
423
440
  this.placedOrderInfo = null;
424
441
  this.clientSecret = cart.stripeStore.clientSecret;
442
+ this.stripeCustomerSessionClientSecret = cart.stripeStore.stripeCustomerSessionClientSecret;
425
443
  }
426
444
  /**
427
445
  * Init cart info handler event
@@ -482,6 +500,8 @@ const ZonosCheckout = class {
482
500
  cartId = cartIdResult.cartId;
483
501
  // set prefill address if provided in createCartId callback result
484
502
  this.useShippingDataFromCreateCartId(cartIdResult.shippingData);
503
+ cart.cartStore.customerAuthenticationToken =
504
+ cartIdResult.customerAuthenticationToken || null;
485
505
  }
486
506
  else {
487
507
  cartId = cartIdResult;
@@ -696,11 +716,11 @@ const ZonosCheckout = class {
696
716
  isPreview: this.preview,
697
717
  sessionTimeout: CHECKOUT_SESSION_TIMEOUT,
698
718
  });
719
+ paypal.submitGtag('zonos-checkout-start');
720
+ void cart.trackConversionEvent('checkout_open');
699
721
  const { enabled } = await isStoreDiscountEnabled();
700
722
  // Hide discount input if there's no active discount configured for the store
701
723
  cart.cartStore.shouldHideDiscountInput = !enabled;
702
- paypal.submitGtag('zonos-checkout-start');
703
- void cart.trackConversionEvent('checkout_open');
704
724
  this.handleOrderDuplication();
705
725
  if (window.Zonos.isLegacyCheckout) {
706
726
  void sendLoadCheckoutFacadeLog();
@@ -840,7 +860,6 @@ const ZonosCheckout = class {
840
860
  const phone = address.customerPhone || '';
841
861
  const postal_code = address.customerZip || '';
842
862
  const state = address.customerState || '';
843
- const countryCode = country === 'UK' ? 'GB' : country;
844
863
  /**
845
864
  * If one of the value is null, no need to preset the default address.
846
865
  * City and state are optional (they are not always provided for example Puerto Rico)
@@ -856,19 +875,27 @@ const ZonosCheckout = class {
856
875
  .join(', '));
857
876
  return;
858
877
  }
859
- this.defaultAddressParams = {
860
- address: {
861
- city: city || '',
862
- country: countryCode,
863
- line1,
864
- line2,
865
- postal_code,
866
- state,
878
+ if (country &&
879
+ cart.localizationStore.shippingZoneCountries &&
880
+ !(country in cart.localizationStore.shippingZoneCountries)) {
881
+ handleFetch.log(`Country "${country}" is not in the shipping zone, so it can not be prefilled`, 'warn');
882
+ return;
883
+ }
884
+ this.defaultAddressParams = [
885
+ {
886
+ address: {
887
+ city: city || '',
888
+ country,
889
+ line1,
890
+ line2,
891
+ postal_code,
892
+ state,
893
+ },
894
+ email,
895
+ name,
896
+ phone,
867
897
  },
868
- email,
869
- name,
870
- phone,
871
- };
898
+ ];
872
899
  handleFetch.log('Prefill address applied', 'info', {
873
900
  prefillAddress: this.defaultAddressParams,
874
901
  providedAddress: address,
@@ -894,19 +921,21 @@ const ZonosCheckout = class {
894
921
  domesticRedirectedBtnSelector: CheckoutConfig.domesticRedirectedBtnSelector,
895
922
  onShippingAddressSessionFound: shippingAddressSession => {
896
923
  // prefilled the default address if shipping address session is found for checkout on open
897
- this.defaultAddress = {
898
- address: {
899
- city: shippingAddressSession.city,
900
- country: shippingAddressSession.countryCode,
901
- line1: shippingAddressSession.address1,
902
- line2: shippingAddressSession.address2,
903
- postal_code: shippingAddressSession.postalCode,
904
- state: shippingAddressSession.state,
924
+ this.defaultAddress = [
925
+ {
926
+ address: {
927
+ city: shippingAddressSession.city,
928
+ country: shippingAddressSession.countryCode,
929
+ line1: shippingAddressSession.address1,
930
+ line2: shippingAddressSession.address2,
931
+ postal_code: shippingAddressSession.postalCode,
932
+ state: shippingAddressSession.state,
933
+ },
934
+ email: '',
935
+ name: `${shippingAddressSession.firstName} ${shippingAddressSession.lastName}`,
936
+ phone: shippingAddressSession.phone,
905
937
  },
906
- email: '',
907
- name: `${shippingAddressSession.firstName} ${shippingAddressSession.lastName}`,
908
- phone: shippingAddressSession.phone,
909
- };
938
+ ];
910
939
  },
911
940
  });
912
941
  /**
@@ -1149,9 +1178,39 @@ const ZonosCheckout = class {
1149
1178
  handleAddressChange() {
1150
1179
  cart.stripeStoreReset();
1151
1180
  }
1181
+ handleCustomerProfileChange() {
1182
+ var _a, _b;
1183
+ if (!this.customerProfile) {
1184
+ handleFetch.log('No customer profile', 'info');
1185
+ this.defaultCustomerProfileAddress = [];
1186
+ return;
1187
+ }
1188
+ handleFetch.log('Customer profile found', 'info', {
1189
+ customerProfile: this.customerProfile,
1190
+ });
1191
+ // Build and set saved locations from checkout customers
1192
+ this.defaultCustomerProfileAddress =
1193
+ ((_b = (_a = cart.stripeStore.customerProfile) === null || _a === void 0 ? void 0 : _a.locations) === null || _b === void 0 ? void 0 : _b.map(location => {
1194
+ var _a;
1195
+ return {
1196
+ address: {
1197
+ city: location.locality,
1198
+ country: location.countryCode,
1199
+ line1: location.line1,
1200
+ line2: location.line2 || '',
1201
+ postal_code: location.postalCode,
1202
+ state: location.administrativeArea,
1203
+ },
1204
+ email: location.email || ((_a = cart.stripeStore.customerProfile) === null || _a === void 0 ? void 0 : _a.email) || '',
1205
+ name: location.name || '',
1206
+ phone: location.phone || '',
1207
+ };
1208
+ })) || [];
1209
+ }
1152
1210
  handleClientSecretChange() {
1153
- handleFetch.log('=== Client secret changed', 'info', {
1154
- clientSecret: cart.stripeStore.clientSecret,
1211
+ handleFetch.log('==== Client secret changed', 'info', {
1212
+ clientSecret: this.clientSecret,
1213
+ stripeCustomerSessionClientSecret: this.stripeCustomerSessionClientSecret,
1155
1214
  });
1156
1215
  // apply theme to stripe elements
1157
1216
  void this.applyStripeTheme();
@@ -1173,6 +1232,8 @@ const ZonosCheckout = class {
1173
1232
  html.style.overflow = 'hidden';
1174
1233
  }
1175
1234
  else {
1235
+ // Should reset stripeCustomerSessionClientSecret state when dialog is closed since merchant would need to re-authenticate, get an OTP again and we will get a new customer session.
1236
+ this.stripeCustomerSessionClientSecret = null;
1176
1237
  const bodyOverflow = body.getAttribute(overflowAttrKey);
1177
1238
  const htmlOverflow = html.getAttribute(overflowAttrKey);
1178
1239
  // reset overflow state to original state
@@ -1220,8 +1281,15 @@ const ZonosCheckout = class {
1220
1281
  }
1221
1282
  render() {
1222
1283
  var _a, _b, _c, _d;
1284
+ this.customerProfile = cart.stripeStore.customerProfile;
1223
1285
  // Set client secret so that we can add this to @Watch listener
1224
1286
  this.clientSecret = cart.stripeStore.clientSecret;
1287
+ // Only set and update stripeCustomerSession state if it's available, since it would only be available at the time checkout session is created, afterward access checkout session the value would be `null`.
1288
+ if (cart.stripeStore.stripeCustomerSessionClientSecret) {
1289
+ // Set stripe customer session client secret so that we can add this to @Watch listener
1290
+ this.stripeCustomerSessionClientSecret =
1291
+ cart.stripeStore.stripeCustomerSessionClientSecret;
1292
+ }
1225
1293
  const dialogLoading =
1226
1294
  // if it's last step, don't need to check stripe elements
1227
1295
  (cart.cartStore.step !== 'finish' &&
@@ -1274,7 +1342,7 @@ const ZonosCheckout = class {
1274
1342
  '--zonos--primary-color': !this.isMobile
1275
1343
  ? colorPrimary
1276
1344
  : undefined,
1277
- }) }, !this.isMobile && renderTopHeader(), cart.cartStore.step === 'customer-info' && (index.h("zonos-customer-info", { continueLoading: this.submitLoading, defaultAddress: this.defaultAddress || this.defaultAddressParams, isMobile: this.isMobile, onContinueClicked: () => this.handleCustomerInfoContinue(), submitBtnColor: submitButtonColor })), cart.cartStore.step === 'shipping' && (index.h("zonos-shipping", { continueLoading: this.submitLoading, onContinueClicked: () => this.handleShippingContinue(), submitBtnColor: submitButtonColor })), cart.cartStore.step === 'payment' && (index.h("zonos-checkout-payment", { continueLoading: this.submitLoading, isMobile: this.isMobile, onContinueClicked: async () => {
1345
+ }) }, !this.isMobile && renderTopHeader(), cart.cartStore.step === 'customer-info' && (index.h("zonos-customer-info", { continueLoading: this.submitLoading, defaultAddress: this.getDefaultAddress(), isMobile: this.isMobile, onContinueClicked: () => this.handleCustomerInfoContinue(), submitBtnColor: submitButtonColor })), cart.cartStore.step === 'shipping' && (index.h("zonos-shipping", { continueLoading: this.submitLoading, onContinueClicked: () => this.handleShippingContinue(), submitBtnColor: submitButtonColor })), cart.cartStore.step === 'payment' && (index.h("zonos-checkout-payment", { continueLoading: this.submitLoading, isMobile: this.isMobile, onContinueClicked: async () => {
1278
1346
  await this.handleStripePaymentContinue();
1279
1347
  }, submitBtnColor: submitButtonColor }))), index.h("div", { class: "zonos--right", "data-theme": rightSideTheme }, this.isMobile && renderTopHeader(), index.h("div", { class: "zonos--right-actions" }, window.Zonos.showBaseForeign && (index.h("zonos-currency-toggle", null)), !this.isLegacyCheckout && (index.h("zonos-button", { class: "zonos--close-button", icon: index.h("zonos-icon", { "aria-label": "Close checkout dialog", content: RemoveIcon.RemoveIcon }), noBackground: true, onClick: () => this.closeDialogHandler() }))), index.h("div", { class: "flex--wrapper" }, index.h("div", { class: "zonos--wrapper" }, index.h("zonos-review", { collapsed: this.collapseReviewMobile, mobile: this.isMobile, onClick: () => {
1280
1348
  // do nothing if it's not mobile
@@ -1353,7 +1421,9 @@ const ZonosCheckout = class {
1353
1421
  "overrideStagingMode": ["overrideStagingModeChanged"],
1354
1422
  "mobile": ["handleMobileChange"],
1355
1423
  "defaultAddress": ["handleAddressChange"],
1424
+ "customerProfile": ["handleCustomerProfileChange"],
1356
1425
  "clientSecret": ["handleClientSecretChange"],
1426
+ "stripeCustomerSessionClientSecret": ["handleClientSecretChange"],
1357
1427
  "open": ["handleOpenChange"]
1358
1428
  }; }
1359
1429
  };
@@ -3,9 +3,9 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  const index = require('./index-2f90486e.js');
6
- const cart = require('./cart-36799bbe.js');
6
+ const cart = require('./cart-d9052930.js');
7
7
  const zonosStore = require('./zonosStore-3812b318.js');
8
- const handleFetch = require('./handleFetch-7b7f9f7c.js');
8
+ const handleFetch = require('./handleFetch-ff25db40.js');
9
9
  require('./isDarkColor-ec4a4e7d.js');
10
10
  require('./getBorderRadius-94ef609c.js');
11
11
 
@@ -3,10 +3,10 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  const index = require('./index-2f90486e.js');
6
- const cart = require('./cart-36799bbe.js');
6
+ const cart = require('./cart-d9052930.js');
7
7
  const zonosStore = require('./zonosStore-3812b318.js');
8
8
  const classes = require('./classes-b7918f56.js');
9
- require('./handleFetch-7b7f9f7c.js');
9
+ require('./handleFetch-ff25db40.js');
10
10
  require('./isDarkColor-ec4a4e7d.js');
11
11
  require('./getBorderRadius-94ef609c.js');
12
12
 
@@ -3,12 +3,12 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  const index = require('./index-2f90486e.js');
6
- const cart = require('./cart-36799bbe.js');
6
+ const cart = require('./cart-d9052930.js');
7
7
  const zonosStore = require('./zonosStore-3812b318.js');
8
8
  const formatStringWithLinks = require('./formatStringWithLinks-52341fc7.js');
9
9
  const isDarkColor = require('./isDarkColor-ec4a4e7d.js');
10
10
  const ILanguage = require('./ILanguage-98b04442.js');
11
- require('./handleFetch-7b7f9f7c.js');
11
+ require('./handleFetch-ff25db40.js');
12
12
  require('./getBorderRadius-94ef609c.js');
13
13
 
14
14
  /**
@@ -19,7 +19,7 @@ var patchBrowser = () => {
19
19
 
20
20
  patchBrowser().then(async (options) => {
21
21
  await appGlobals.globalScripts();
22
- return index.bootstrapLazy(JSON.parse("[[\"zonos-checkout.cjs\",[[2,\"zonos-checkout\",{\"appearanceSettingsOverride\":[16],\"preview\":[4],\"mobile\":[4],\"overrideStagingMode\":[4,\"override-staging-mode\"],\"defaultAddress\":[16],\"forceDialogOpen\":[4,\"force-dialog-open\"],\"defaultAddressParams\":[32],\"open\":[32],\"stripe\":[32],\"submitLoading\":[32],\"collapseReviewMobile\":[32],\"isAttachError\":[32],\"isMobile\":[32],\"isIframed\":[32],\"zonosReviewRef\":[32],\"storybookPaymentStatusOverride\":[32],\"isLegacyCheckout\":[32],\"confirmDialogOpen\":[32],\"isCartExpired\":[32],\"payInUsdConfirmDialogOpen\":[32],\"inventoryCheckErrorMessage\":[32],\"placedOrderInfo\":[32],\"clientSecret\":[32],\"closeDialogHandler\":[64],\"init\":[64],\"setToFinishStep\":[64],\"mockCheckoutSession\":[64]},[[16,\"zonos--init-cart-info\",\"initCartInfoHandler\"],[4,\"keydown\",\"handleKeyPress\"],[9,\"resize\",\"handleWindowResize\"]],{\"appearanceSettingsOverride\":[\"appearanceSettingsOverrideChanged\",\"handleAppearanceSettingsOverrideChange\"],\"overrideStagingMode\":[\"overrideStagingModeChanged\"],\"mobile\":[\"handleMobileChange\"],\"defaultAddress\":[\"handleAddressChange\"],\"clientSecret\":[\"handleClientSecretChange\"],\"open\":[\"handleOpenChange\"]}]]],[\"zonos-hello.cjs\",[[1,\"zonos-hello\",{\"mobileLocationOverride\":[1,\"mobile-location-override\"],\"animateFromLeftOverride\":[4,\"animate-from-left-override\"],\"appearanceSettingsOverride\":[16],\"showPeekMessage\":[32],\"zonosStoreHelloSettings\":[32],\"showDialog\":[32],\"peekMessage\":[32],\"initialUrl\":[32],\"allRestrictedItems\":[32],\"allFoundProducts\":[32],\"productsOnPage\":[32],\"isHelloWidgetRendered\":[32],\"isMobile\":[32],\"getCountryList\":[64],\"displayCurrency\":[64],\"convertAndFormat\":[64],\"convert\":[64],\"format\":[64],\"openHelloDialog\":[64]},[[9,\"resize\",\"handleResize\"]],{\"appearanceSettingsOverride\":[\"handleAppearanceSettingsOverrideChange\"]}]]],[\"zonos-controller.cjs\",[[1,\"zonos-controller\",{\"config\":[16],\"zonosApiKey\":[1,\"zonos-api-key\"],\"initCheckoutElement\":[64],\"setupGoogleFont\":[64],\"showNotification\":[64],\"reset\":[64],\"overrideConfig\":[64],\"overrideCountry\":[64],\"getAppearanceSetting\":[64],\"updateOrganizationName\":[64]},[[8,\"locationchange\",\"handleLocationChange\"]]]]],[\"zonos-tooltip.cjs\",[[1,\"zonos-tooltip\",{\"label\":[1],\"subtitle\":[1],\"showTooltip\":[32]}]]],[\"zonos-component.cjs\",[[1,\"zonos-component\",{\"first\":[1],\"middle\":[1],\"last\":[1]}]]],[\"zonos-link.cjs\",[[1,\"zonos-link\",{\"href\":[1],\"rel\":[1],\"target\":[1],\"linkTitle\":[1,\"link-title\"]}]]],[\"zonos-logo.cjs\",[[1,\"zonos-logo\",{\"theme\":[1],\"width\":[1]}]]],[\"zonos-hello-dialog.cjs\",[[1,\"zonos-hello-dialog\",{\"isOpen\":[4,\"is-open\"],\"setIsOpen\":[16],\"mobileLocationOverride\":[1,\"mobile-location-override\"],\"animateFromLeftOverride\":[4,\"animate-from-left-override\"],\"appearanceSettings\":[16],\"restrictedItems\":[16],\"welcomeMessage\":[32],\"showCountrySelect\":[32],\"showLanguageSelect\":[32]},[[4,\"click\",\"globalClickHandler\"]],{\"isOpen\":[\"isOpenHandler\"]}]]],[\"zonos-badge.cjs\",[[1,\"zonos-badge\",{\"bold\":[4],\"badgeColor\":[1,\"badge-color\"],\"icon\":[16],\"iconRight\":[4,\"icon-right\"],\"size\":[1],\"rounded\":[4],\"loading\":[4],\"dismissHandler\":[16]}]]],[\"zonos-shipping-rich-radio.cjs\",[[1,\"zonos-shipping-rich-radio\",{\"items\":[16],\"borderColor\":[1,\"border-color\"],\"borderStyle\":[1,\"border-style\"],\"theme\":[1],\"selectedItem\":[16]}]]],[\"zonos-toggle.cjs\",[[1,\"zonos-toggle\",{\"options\":[16],\"value\":[1]}]]],[\"zonos-collapse.cjs\",[[1,\"zonos-collapse\",{\"collapsed\":[4],\"collapseSize\":[2,\"collapse-size\"],\"height\":[32],\"iframe\":[32]}]]],[\"zonos-stripe-input.cjs\",[[1,\"zonos-stripe-input\",{\"inputValue\":[1,\"input-value\"],\"inputLabel\":[1,\"input-label\"],\"overridePrimaryColor\":[1,\"override-primary-color\"],\"overrideSecondaryColor\":[1,\"override-secondary-color\"],\"isDisabled\":[4,\"is-disabled\"],\"isError\":[4,\"is-error\"],\"inputPlaceholder\":[1,\"input-placeholder\"],\"value\":[1025],\"internalValue\":[32]},null,{\"inputValue\":[\"onInputValueChange\"],\"value\":[\"onValueChange\"]}]]],[\"zonos-card.cjs\",[[1,\"zonos-card\",{\"actions\":[16],\"backgroundColor\":[1,\"background-color\"],\"borderRadius\":[2,\"border-radius\"],\"footerActions\":[16],\"footerContent\":[16],\"footerHeight\":[2,\"footer-height\"],\"label\":[16],\"spacing\":[1]}]]],[\"zonos-input.cjs\",[[1,\"zonos-input\",{\"inputValue\":[1,\"input-value\"],\"inputLabel\":[1,\"input-label\"],\"inputSize\":[1,\"input-size\"],\"isDisabled\":[4,\"is-disabled\"],\"isError\":[4,\"is-error\"],\"inputPlaceholder\":[1,\"input-placeholder\"],\"value\":[32]},null,{\"inputValue\":[\"onInputValueChange\"]}]]],[\"zonos-text.cjs\",[[1,\"zonos-text\",{\"textColor\":[1,\"text-color\"],\"size\":[1],\"type\":[1],\"weight\":[2],\"ready\":[32]}]]],[\"zonos-banner.cjs\",[[1,\"zonos-banner\",{\"bannerTitle\":[1,\"banner-title\"],\"intent\":[1],\"hasContent\":[32]}]]],[\"zonos-country-flag.cjs\",[[1,\"zonos-country-flag\",{\"countryCode\":[1,\"country-code\"],\"size\":[2]}]]],[\"zonos-v-stack.cjs\",[[1,\"zonos-v-stack\",{\"spacing\":[2]}]]],[\"zonos-empty-state-payment_4.cjs\",[[1,\"zonos-empty-state-payment\",{\"emptyStateText\":[1,\"empty-state-text\"],\"theme\":[1]}],[2,\"zonos-payment\",{\"titleText\":[1,\"title-text\"],\"stripe\":[32],\"stripeElements\":[32]},null,{\"stripeElements\":[\"watchInitStripe\"],\"stripe\":[\"watchInitStripe\"]}],[2,\"zonos-paypal-payment\"],[1,\"zonos-notification\",{\"notificationArray\":[32],\"showNotification\":[64]}]]],[\"zonos-button_3.cjs\",[[17,\"zonos-button\",{\"buttonColor\":[1,\"button-color\"],\"backgroundColor\":[1,\"background-color\"],\"borderStyle\":[1,\"border-style\"],\"isDisabled\":[4,\"is-disabled\"],\"icon\":[16],\"iconRight\":[4,\"icon-right\"],\"size\":[1],\"variant\":[1],\"noBackground\":[4,\"no-background\"],\"withBoxShadow\":[4,\"with-box-shadow\"],\"noPaddingLeft\":[4,\"no-padding-left\"],\"noPaddingRight\":[4,\"no-padding-right\"],\"loading\":[4],\"justifyContent\":[1,\"justify-content\"],\"bold\":[4],\"theme\":[1],\"hasIcon\":[32],\"hasContent\":[32]},[[2,\"click\",\"clickHandler\"]],{\"icon\":[\"iconChangeHandler\"]}],[1,\"zonos-spinner\",{\"size\":[2],\"spinnerColor\":[1,\"spinner-color\"]}],[1,\"zonos-icon\",{\"autoHeight\":[4,\"auto-height\"],\"iconColor\":[1,\"icon-color\"],\"content\":[1],\"size\":[2]}]]],[\"zonos-language-select_2.cjs\",[[1,\"zonos-language-select\",{\"handleOnClose\":[16]}],[1,\"zonos-select-dialog-header\",{\"handleOnClose\":[16],\"label\":[1]}]]],[\"zonos-country-select_4.cjs\",[[1,\"zonos-country-select\",{\"handleOnClose\":[16],\"inputValue\":[32]}],[1,\"zonos-hello-dialog-footer\",{\"appearanceSettings\":[16],\"setShowCountrySelect\":[16],\"setShowLanguageSelect\":[16]}],[1,\"zonos-custom-message\",{\"icon\":[1],\"message\":[1]}],[2,\"zonos-virtual-scroll\",{\"renderItem\":[16],\"itemWidth\":[2,\"item-width\"],\"fallbackItemHeight\":[2,\"fallback-item-height\"],\"itemHeights\":[16],\"container\":[32],\"scrollTop\":[32],\"totalHeight\":[32]},null,{\"itemHeights\":[\"updateTotalHeight\"],\"fallbackItemHeight\":[\"updateTotalHeight\"]}]]],[\"zonos-address_7.cjs\",[[1,\"zonos-address-update-dialog\",{\"continueLoading\":[4,\"continue-loading\"],\"dialogLoading\":[4,\"dialog-loading\"],\"dialogOpen\":[4,\"dialog-open\"],\"submitBtnType\":[1,\"submit-btn-type\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"isMobile\":[4,\"is-mobile\"],\"shippingAddress\":[16],\"billingAddress\":[16],\"translatedShippingAddress\":[16],\"translatedBillingAddress\":[16],\"showErrorBanner\":[32],\"translatedShippingAddressState\":[32],\"translatedBillingAddressState\":[32]},null,{\"translatedShippingAddress\":[\"watchTranslatedShippingAddress\"],\"translatedBillingAddress\":[\"watchTranslatedBillingAddress\"]}],[2,\"zonos-address\",{\"type\":[1],\"titleText\":[1,\"title-text\"],\"defaultAddress\":[16],\"stripe\":[32],\"isDirtyAddress\":[32]},null,{\"stripe\":[\"watchInitStripe\"],\"defaultAddress\":[\"defaultAddressChanged\"]}],[2,\"zonos-link-authentication\",{\"titleText\":[1,\"title-text\"],\"defaultEmail\":[1,\"default-email\"],\"isEmailError\":[4,\"is-email-error\"],\"stripe\":[32],\"isStagingMode\":[32],\"clientSecret\":[32]},null,{\"isStagingMode\":[\"watchIsStagingMode\"],\"stripe\":[\"watchInitStripe\"],\"clientSecret\":[\"watchInitStripe\"],\"defaultEmail\":[\"watchDefaultEmail\"]}],[1,\"zonos-checkbox\",{\"backgroundColor\":[1,\"background-color\"],\"label\":[1],\"isChecked\":[4,\"is-checked\"],\"isDisabled\":[4,\"is-disabled\"],\"size\":[2],\"fontSize\":[1,\"font-size\"],\"borderStyle\":[1,\"border-style\"]},[[1,\"click\",\"onClick\"]]],[1,\"zonos-dialog\",{\"open\":[4],\"headerText\":[1,\"header-text\"],\"width\":[1],\"height\":[1],\"minHeight\":[1,\"min-height\"],\"noHeader\":[4,\"no-header\"],\"noBodyPadding\":[4,\"no-body-padding\"],\"noBorder\":[4,\"no-border\"],\"borderStyle\":[1,\"border-style\"],\"noCloseButton\":[4,\"no-close-button\"],\"noClickOutside\":[4,\"no-click-outside\"],\"mobile\":[4],\"isLoading\":[4,\"is-loading\"],\"isMobile\":[32]},[[9,\"resize\",\"handleWindowResize\"],[4,\"keydown\",\"handleKeyDown\"]]],[1,\"zonos-address-display\",{\"currentAddress\":[16],\"addressType\":[1,\"address-type\"]}],[1,\"zonos-address-form\",{\"currentAddress\":[16],\"translatedAddress\":[16],\"addressType\":[1,\"address-type\"],\"localAddress\":[32]},null,{\"translatedAddress\":[\"watchCurrentAddress\"]}]]],[\"zonos-cart-items_13.cjs\",[[2,\"zonos-customer-info\",{\"continueLoading\":[4,\"continue-loading\"],\"submitBtnType\":[1,\"submit-btn-type\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"isMobile\":[4,\"is-mobile\"],\"defaultAddress\":[16],\"showErrorBanner\":[32],\"shippingCountry\":[32],\"isCheckingForRestrictedItems\":[32],\"isValidatingAddress\":[32],\"isTaxIdError\":[32],\"invalidShippingCharacterList\":[32],\"invalidBillingCharacterList\":[32],\"openAddressValidationDialog\":[32],\"isEmailError\":[32]}],[2,\"zonos-checkout-payment\",{\"submitBtnType\":[1,\"submit-btn-type\"],\"continueLoading\":[4,\"continue-loading\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"isMobile\":[4,\"is-mobile\"],\"overridePrimaryColor\":[1,\"override-primary-color\"],\"showErrorBanner\":[32],\"hasStripePaymentError\":[32],\"stagingOrderCreateErrorMessage\":[32],\"internalContinueLoading\":[32]},null,{\"continueLoading\":[\"continueLoadingWatcher\"],\"hasStripePaymentError\":[\"stripePaymentErrorWatcher\"]}],[1,\"zonos-checkout-footer\",{\"mobile\":[4],\"dataTheme\":[1,\"data-theme\"],\"showLanguageDialog\":[32],\"isMobile\":[32]},[[4,\"click\",\"handleGlobalClick\"]],{\"mobile\":[\"handleMobileChange\"]}],[2,\"zonos-shipping\",{\"continueLoading\":[4,\"continue-loading\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"submitBtnType\":[1,\"submit-btn-type\"],\"selectedShippingMethod\":[32],\"collapsedDAPOptions\":[32],\"isSelecting\":[32],\"showErrorBanner\":[32],\"serviceLevelsDDP\":[32],\"serviceLevelsDAP\":[32],\"serviceLevelsOther\":[32],\"serviceLevelsAll\":[32],\"displayBaseCurrency\":[32]}],[1,\"zonos-cart-subtotal\",{\"submitBtnType\":[1,\"submit-btn-type\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"loading\":[32]}],[1,\"zonos-cart-restricted-items\",{\"hide\":[4],\"errorImages\":[32],\"internalCollapsed\":[32],\"firstRender\":[32]}],[1,\"zonos-checkout-finish\",{\"borderRadius\":[1,\"border-radius\"],\"storybookForceStatus\":[1,\"storybook-force-status\"],\"overrideNotification\":[16],\"isLoading\":[32],\"notificationType\":[32],\"notificationTitle\":[32],\"notificationMessages\":[32],\"notificationActionText\":[32],\"order\":[32],\"isWaitingToRedirect\":[32]}],[1,\"zonos-confirm-dialog\",{\"dialogTitle\":[1,\"dialog-title\"],\"dialogIntent\":[1,\"dialog-intent\"],\"dialogSubtitle\":[1,\"dialog-subtitle\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"dialogConfirmBtnText\":[1,\"dialog-confirm-btn-text\"],\"dialogWidth\":[2,\"dialog-width\"],\"dialogCancelBtnText\":[1,\"dialog-cancel-btn-text\"],\"dialogType\":[1,\"dialog-type\"],\"isMobile\":[4,\"is-mobile\"],\"dialogOpen\":[4,\"dialog-open\"],\"noClickOutside\":[4,\"no-click-outside\"]},[[4,\"keydown\",\"handleKeyDown\"]]],[1,\"zonos-checkout-progress-tabs\",{\"tabColor\":[1,\"tab-color\"],\"backgroundColor\":[1,\"background-color\"],\"setTabItems\":[64],\"setTabSelected\":[64]}],[1,\"zonos-review\",{\"mobile\":[4],\"collapsed\":[4],\"isMobile\":[32]},[[9,\"resize\",\"handleWindowResize\"]]],[1,\"zonos-cart-items\",{\"errorImages\":[32]}],[1,\"zonos-currency-toggle\",{\"errorImages\":[32]}],[1,\"zonos-rest-state\",{\"restStateSubtitle\":[1,\"rest-state-subtitle\"],\"restStateTitle\":[1,\"rest-state-title\"],\"restStateType\":[1,\"rest-state-type\"],\"isErrorImageLoad\":[32]}]]]]"), options);
22
+ return index.bootstrapLazy(JSON.parse("[[\"zonos-checkout.cjs\",[[2,\"zonos-checkout\",{\"appearanceSettingsOverride\":[16],\"preview\":[4],\"mobile\":[4],\"overrideStagingMode\":[4,\"override-staging-mode\"],\"defaultAddress\":[16],\"forceDialogOpen\":[4,\"force-dialog-open\"],\"defaultAddressParams\":[32],\"defaultCustomerProfileAddress\":[32],\"customerProfile\":[32],\"open\":[32],\"stripe\":[32],\"submitLoading\":[32],\"collapseReviewMobile\":[32],\"isAttachError\":[32],\"isMobile\":[32],\"isIframed\":[32],\"zonosReviewRef\":[32],\"storybookPaymentStatusOverride\":[32],\"isLegacyCheckout\":[32],\"confirmDialogOpen\":[32],\"isCartExpired\":[32],\"payInUsdConfirmDialogOpen\":[32],\"inventoryCheckErrorMessage\":[32],\"placedOrderInfo\":[32],\"clientSecret\":[32],\"stripeCustomerSessionClientSecret\":[32],\"closeDialogHandler\":[64],\"init\":[64],\"setToFinishStep\":[64],\"mockCheckoutSession\":[64]},[[16,\"zonos--init-cart-info\",\"initCartInfoHandler\"],[4,\"keydown\",\"handleKeyPress\"],[9,\"resize\",\"handleWindowResize\"]],{\"appearanceSettingsOverride\":[\"appearanceSettingsOverrideChanged\",\"handleAppearanceSettingsOverrideChange\"],\"overrideStagingMode\":[\"overrideStagingModeChanged\"],\"mobile\":[\"handleMobileChange\"],\"defaultAddress\":[\"handleAddressChange\"],\"customerProfile\":[\"handleCustomerProfileChange\"],\"clientSecret\":[\"handleClientSecretChange\"],\"stripeCustomerSessionClientSecret\":[\"handleClientSecretChange\"],\"open\":[\"handleOpenChange\"]}]]],[\"zonos-hello.cjs\",[[1,\"zonos-hello\",{\"mobileLocationOverride\":[1,\"mobile-location-override\"],\"animateFromLeftOverride\":[4,\"animate-from-left-override\"],\"appearanceSettingsOverride\":[16],\"showPeekMessage\":[32],\"zonosStoreHelloSettings\":[32],\"showDialog\":[32],\"peekMessage\":[32],\"initialUrl\":[32],\"allRestrictedItems\":[32],\"allFoundProducts\":[32],\"productsOnPage\":[32],\"isHelloWidgetRendered\":[32],\"isMobile\":[32],\"getCountryList\":[64],\"displayCurrency\":[64],\"convertAndFormat\":[64],\"convert\":[64],\"format\":[64],\"openHelloDialog\":[64]},[[9,\"resize\",\"handleResize\"]],{\"appearanceSettingsOverride\":[\"handleAppearanceSettingsOverrideChange\"]}]]],[\"zonos-controller.cjs\",[[1,\"zonos-controller\",{\"config\":[16],\"zonosApiKey\":[1,\"zonos-api-key\"],\"initCheckoutElement\":[64],\"setupGoogleFont\":[64],\"showNotification\":[64],\"reset\":[64],\"overrideConfig\":[64],\"overrideCountry\":[64],\"getAppearanceSetting\":[64],\"updateOrganizationName\":[64]},[[8,\"locationchange\",\"handleLocationChange\"]]]]],[\"zonos-tooltip.cjs\",[[1,\"zonos-tooltip\",{\"label\":[1],\"subtitle\":[1],\"showTooltip\":[32]}]]],[\"zonos-component.cjs\",[[1,\"zonos-component\",{\"first\":[1],\"middle\":[1],\"last\":[1]}]]],[\"zonos-link.cjs\",[[1,\"zonos-link\",{\"href\":[1],\"rel\":[1],\"target\":[1],\"linkTitle\":[1,\"link-title\"]}]]],[\"zonos-logo.cjs\",[[1,\"zonos-logo\",{\"theme\":[1],\"width\":[1]}]]],[\"zonos-hello-dialog.cjs\",[[1,\"zonos-hello-dialog\",{\"isOpen\":[4,\"is-open\"],\"setIsOpen\":[16],\"mobileLocationOverride\":[1,\"mobile-location-override\"],\"animateFromLeftOverride\":[4,\"animate-from-left-override\"],\"appearanceSettings\":[16],\"restrictedItems\":[16],\"welcomeMessage\":[32],\"showCountrySelect\":[32],\"showLanguageSelect\":[32]},[[4,\"click\",\"globalClickHandler\"]],{\"isOpen\":[\"isOpenHandler\"]}]]],[\"zonos-badge.cjs\",[[1,\"zonos-badge\",{\"bold\":[4],\"badgeColor\":[1,\"badge-color\"],\"icon\":[16],\"iconRight\":[4,\"icon-right\"],\"size\":[1],\"rounded\":[4],\"loading\":[4],\"dismissHandler\":[16]}]]],[\"zonos-shipping-rich-radio.cjs\",[[1,\"zonos-shipping-rich-radio\",{\"items\":[16],\"borderColor\":[1,\"border-color\"],\"borderStyle\":[1,\"border-style\"],\"theme\":[1],\"selectedItem\":[16]}]]],[\"zonos-toggle.cjs\",[[1,\"zonos-toggle\",{\"options\":[16],\"value\":[1]}]]],[\"zonos-collapse.cjs\",[[1,\"zonos-collapse\",{\"collapsed\":[4],\"collapseSize\":[2,\"collapse-size\"],\"height\":[32],\"iframe\":[32]}]]],[\"zonos-stripe-input.cjs\",[[1,\"zonos-stripe-input\",{\"inputValue\":[1,\"input-value\"],\"inputLabel\":[1,\"input-label\"],\"overridePrimaryColor\":[1,\"override-primary-color\"],\"overrideSecondaryColor\":[1,\"override-secondary-color\"],\"isDisabled\":[4,\"is-disabled\"],\"isError\":[4,\"is-error\"],\"inputPlaceholder\":[1,\"input-placeholder\"],\"value\":[1025],\"internalValue\":[32]},null,{\"inputValue\":[\"onInputValueChange\"],\"value\":[\"onValueChange\"]}]]],[\"zonos-card.cjs\",[[1,\"zonos-card\",{\"actions\":[16],\"backgroundColor\":[1,\"background-color\"],\"borderRadius\":[2,\"border-radius\"],\"footerActions\":[16],\"footerContent\":[16],\"footerHeight\":[2,\"footer-height\"],\"label\":[16],\"spacing\":[1]}]]],[\"zonos-input.cjs\",[[1,\"zonos-input\",{\"inputValue\":[1,\"input-value\"],\"inputLabel\":[1,\"input-label\"],\"inputSize\":[1,\"input-size\"],\"isDisabled\":[4,\"is-disabled\"],\"isError\":[4,\"is-error\"],\"inputPlaceholder\":[1,\"input-placeholder\"],\"value\":[32]},null,{\"inputValue\":[\"onInputValueChange\"]}]]],[\"zonos-text.cjs\",[[1,\"zonos-text\",{\"textColor\":[1,\"text-color\"],\"size\":[1],\"type\":[1],\"weight\":[2],\"ready\":[32]}]]],[\"zonos-banner.cjs\",[[1,\"zonos-banner\",{\"bannerTitle\":[1,\"banner-title\"],\"intent\":[1],\"hasContent\":[32]}]]],[\"zonos-country-flag.cjs\",[[1,\"zonos-country-flag\",{\"countryCode\":[1,\"country-code\"],\"size\":[2]}]]],[\"zonos-v-stack.cjs\",[[1,\"zonos-v-stack\",{\"spacing\":[2]}]]],[\"zonos-empty-state-payment_4.cjs\",[[1,\"zonos-empty-state-payment\",{\"emptyStateText\":[1,\"empty-state-text\"],\"theme\":[1]}],[2,\"zonos-payment\",{\"titleText\":[1,\"title-text\"],\"stripe\":[32],\"stripeElements\":[32],\"isPaymentInfoFilled\":[32]},null,{\"isPaymentInfoFilled\":[\"watchIsPaymentInfoFilled\"],\"stripeElements\":[\"watchInitStripe\"],\"stripe\":[\"watchInitStripe\"]}],[2,\"zonos-paypal-payment\"],[1,\"zonos-notification\",{\"notificationArray\":[32],\"showNotification\":[64]}]]],[\"zonos-button_3.cjs\",[[17,\"zonos-button\",{\"buttonColor\":[1,\"button-color\"],\"backgroundColor\":[1,\"background-color\"],\"borderStyle\":[1,\"border-style\"],\"isDisabled\":[4,\"is-disabled\"],\"icon\":[16],\"iconRight\":[4,\"icon-right\"],\"size\":[1],\"variant\":[1],\"noBackground\":[4,\"no-background\"],\"withBoxShadow\":[4,\"with-box-shadow\"],\"noPaddingLeft\":[4,\"no-padding-left\"],\"noPaddingRight\":[4,\"no-padding-right\"],\"loading\":[4],\"justifyContent\":[1,\"justify-content\"],\"bold\":[4],\"theme\":[1],\"hasIcon\":[32],\"hasContent\":[32]},[[2,\"click\",\"clickHandler\"]],{\"icon\":[\"iconChangeHandler\"]}],[1,\"zonos-spinner\",{\"size\":[2],\"spinnerColor\":[1,\"spinner-color\"]}],[1,\"zonos-icon\",{\"autoHeight\":[4,\"auto-height\"],\"iconColor\":[1,\"icon-color\"],\"content\":[1],\"size\":[2]}]]],[\"zonos-language-select_2.cjs\",[[1,\"zonos-language-select\",{\"handleOnClose\":[16]}],[1,\"zonos-select-dialog-header\",{\"handleOnClose\":[16],\"label\":[1]}]]],[\"zonos-country-select_4.cjs\",[[1,\"zonos-country-select\",{\"handleOnClose\":[16],\"inputValue\":[32]}],[1,\"zonos-hello-dialog-footer\",{\"appearanceSettings\":[16],\"setShowCountrySelect\":[16],\"setShowLanguageSelect\":[16]}],[1,\"zonos-custom-message\",{\"icon\":[1],\"message\":[1]}],[2,\"zonos-virtual-scroll\",{\"renderItem\":[16],\"itemWidth\":[2,\"item-width\"],\"fallbackItemHeight\":[2,\"fallback-item-height\"],\"itemHeights\":[16],\"container\":[32],\"scrollTop\":[32],\"totalHeight\":[32]},null,{\"itemHeights\":[\"updateTotalHeight\"],\"fallbackItemHeight\":[\"updateTotalHeight\"]}]]],[\"zonos-address_7.cjs\",[[1,\"zonos-address-update-dialog\",{\"continueLoading\":[4,\"continue-loading\"],\"dialogLoading\":[4,\"dialog-loading\"],\"dialogOpen\":[4,\"dialog-open\"],\"submitBtnType\":[1,\"submit-btn-type\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"isMobile\":[4,\"is-mobile\"],\"shippingAddress\":[16],\"billingAddress\":[16],\"translatedShippingAddress\":[16],\"translatedBillingAddress\":[16],\"showErrorBanner\":[32],\"translatedShippingAddressState\":[32],\"translatedBillingAddressState\":[32]},null,{\"translatedShippingAddress\":[\"watchTranslatedShippingAddress\"],\"translatedBillingAddress\":[\"watchTranslatedBillingAddress\"]}],[2,\"zonos-address\",{\"type\":[1],\"titleText\":[1,\"title-text\"],\"defaultAddress\":[16],\"stripe\":[32],\"isDirtyAddress\":[32]},null,{\"stripe\":[\"watchInitStripe\"],\"defaultAddress\":[\"defaultAddressChanged\"]}],[2,\"zonos-link-authentication\",{\"titleText\":[1,\"title-text\"],\"defaultEmail\":[1,\"default-email\"],\"isEmailError\":[4,\"is-email-error\"],\"stripe\":[32],\"isStagingMode\":[32],\"clientSecret\":[32]},null,{\"isStagingMode\":[\"watchIsStagingMode\"],\"stripe\":[\"watchInitStripe\"],\"clientSecret\":[\"watchInitStripe\"],\"defaultEmail\":[\"watchDefaultEmail\"]}],[1,\"zonos-checkbox\",{\"backgroundColor\":[1,\"background-color\"],\"label\":[1],\"isChecked\":[4,\"is-checked\"],\"isDisabled\":[4,\"is-disabled\"],\"size\":[2],\"fontSize\":[1,\"font-size\"],\"borderStyle\":[1,\"border-style\"]},[[1,\"click\",\"onClick\"]]],[1,\"zonos-dialog\",{\"open\":[4],\"headerText\":[1,\"header-text\"],\"width\":[1],\"height\":[1],\"minHeight\":[1,\"min-height\"],\"noHeader\":[4,\"no-header\"],\"noBodyPadding\":[4,\"no-body-padding\"],\"noBorder\":[4,\"no-border\"],\"borderStyle\":[1,\"border-style\"],\"noCloseButton\":[4,\"no-close-button\"],\"noClickOutside\":[4,\"no-click-outside\"],\"mobile\":[4],\"isLoading\":[4,\"is-loading\"],\"isMobile\":[32]},[[9,\"resize\",\"handleWindowResize\"],[4,\"keydown\",\"handleKeyDown\"]]],[1,\"zonos-address-display\",{\"currentAddress\":[16],\"addressType\":[1,\"address-type\"]}],[1,\"zonos-address-form\",{\"currentAddress\":[16],\"translatedAddress\":[16],\"addressType\":[1,\"address-type\"],\"localAddress\":[32]},null,{\"translatedAddress\":[\"watchCurrentAddress\"]}]]],[\"zonos-cart-items_13.cjs\",[[2,\"zonos-customer-info\",{\"continueLoading\":[4,\"continue-loading\"],\"submitBtnType\":[1,\"submit-btn-type\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"isMobile\":[4,\"is-mobile\"],\"defaultAddress\":[16],\"showErrorBanner\":[32],\"shippingCountry\":[32],\"isCheckingForRestrictedItems\":[32],\"isValidatingAddress\":[32],\"isTaxIdError\":[32],\"invalidShippingCharacterList\":[32],\"invalidBillingCharacterList\":[32],\"openAddressValidationDialog\":[32],\"isEmailError\":[32]}],[2,\"zonos-checkout-payment\",{\"submitBtnType\":[1,\"submit-btn-type\"],\"continueLoading\":[4,\"continue-loading\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"isMobile\":[4,\"is-mobile\"],\"overridePrimaryColor\":[1,\"override-primary-color\"],\"showErrorBanner\":[32],\"hasStripePaymentError\":[32],\"stagingOrderCreateErrorMessage\":[32],\"internalContinueLoading\":[32]},null,{\"continueLoading\":[\"continueLoadingWatcher\"],\"hasStripePaymentError\":[\"stripePaymentErrorWatcher\"]}],[1,\"zonos-checkout-footer\",{\"mobile\":[4],\"dataTheme\":[1,\"data-theme\"],\"showLanguageDialog\":[32],\"isMobile\":[32]},[[4,\"click\",\"handleGlobalClick\"]],{\"mobile\":[\"handleMobileChange\"]}],[2,\"zonos-shipping\",{\"continueLoading\":[4,\"continue-loading\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"submitBtnType\":[1,\"submit-btn-type\"],\"selectedShippingMethod\":[32],\"collapsedDAPOptions\":[32],\"isSelecting\":[32],\"showErrorBanner\":[32],\"serviceLevelsDDP\":[32],\"serviceLevelsDAP\":[32],\"serviceLevelsOther\":[32],\"serviceLevelsAll\":[32],\"displayBaseCurrency\":[32]}],[1,\"zonos-cart-subtotal\",{\"submitBtnType\":[1,\"submit-btn-type\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"loading\":[32]}],[1,\"zonos-cart-restricted-items\",{\"hide\":[4],\"errorImages\":[32],\"internalCollapsed\":[32],\"firstRender\":[32]}],[1,\"zonos-checkout-finish\",{\"borderRadius\":[1,\"border-radius\"],\"storybookForceStatus\":[1,\"storybook-force-status\"],\"overrideNotification\":[16],\"isLoading\":[32],\"notificationType\":[32],\"notificationTitle\":[32],\"notificationMessages\":[32],\"notificationActionText\":[32],\"order\":[32],\"isWaitingToRedirect\":[32]}],[1,\"zonos-confirm-dialog\",{\"dialogTitle\":[1,\"dialog-title\"],\"dialogIntent\":[1,\"dialog-intent\"],\"dialogSubtitle\":[1,\"dialog-subtitle\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"dialogConfirmBtnText\":[1,\"dialog-confirm-btn-text\"],\"dialogWidth\":[2,\"dialog-width\"],\"dialogCancelBtnText\":[1,\"dialog-cancel-btn-text\"],\"dialogType\":[1,\"dialog-type\"],\"isMobile\":[4,\"is-mobile\"],\"dialogOpen\":[4,\"dialog-open\"],\"noClickOutside\":[4,\"no-click-outside\"]},[[4,\"keydown\",\"handleKeyDown\"]]],[1,\"zonos-checkout-progress-tabs\",{\"tabColor\":[1,\"tab-color\"],\"backgroundColor\":[1,\"background-color\"],\"setTabItems\":[64],\"setTabSelected\":[64]}],[1,\"zonos-review\",{\"mobile\":[4],\"collapsed\":[4],\"isMobile\":[32]},[[9,\"resize\",\"handleWindowResize\"]]],[1,\"zonos-cart-items\",{\"errorImages\":[32]}],[1,\"zonos-currency-toggle\",{\"errorImages\":[32]}],[1,\"zonos-rest-state\",{\"restStateSubtitle\":[1,\"rest-state-subtitle\"],\"restStateTitle\":[1,\"rest-state-title\"],\"restStateType\":[1,\"rest-state-type\"],\"isErrorImageLoad\":[32]}]]]]"), options);
23
23
  });
24
24
 
25
25
  exports.setNonce = index.setNonce;
@@ -6,9 +6,9 @@ const index = require('./index-2f90486e.js');
6
6
  const zonosStore = require('./zonosStore-3812b318.js');
7
7
  const classes = require('./classes-b7918f56.js');
8
8
  const getBorderRadius = require('./getBorderRadius-94ef609c.js');
9
- const cart = require('./cart-36799bbe.js');
10
- const handleFetch = require('./handleFetch-7b7f9f7c.js');
11
- const paypal = require('./paypal-3eae38bd.js');
9
+ const cart = require('./cart-d9052930.js');
10
+ const handleFetch = require('./handleFetch-ff25db40.js');
11
+ const paypal = require('./paypal-31477331.js');
12
12
  require('./isDarkColor-ec4a4e7d.js');
13
13
 
14
14
  const PaymentEmptyStateDarkIcon = `<svg width="536" height="200" viewBox="0 0 536 200" fill="none" xmlns="http://www.w3.org/2000/svg">
@@ -158,9 +158,21 @@ const ZonosPaymentStyle0 = zonosPaymentCss;
158
158
  const ZonosPayment = class {
159
159
  constructor(hostRef) {
160
160
  index.registerInstance(this, hostRef);
161
+ this.trackingSent = false;
161
162
  this.titleText = undefined;
162
163
  this.stripe = cart.stripeStore.stripe;
163
164
  this.stripeElements = cart.stripeStore.stripeElements;
165
+ this.isPaymentInfoFilled = false;
166
+ }
167
+ watchIsPaymentInfoFilled() {
168
+ var _a;
169
+ // Only send event once when payment info is filled
170
+ if (this.isPaymentInfoFilled && !this.trackingSent) {
171
+ void cart.trackConversionEvent('checkout_paymentInfoFilled', {
172
+ paymentMethod: (_a = cart.stripeStore.stripePaymentEventData) === null || _a === void 0 ? void 0 : _a.value.type,
173
+ });
174
+ this.trackingSent = true;
175
+ }
164
176
  }
165
177
  watchInitStripe() {
166
178
  if (!this.stripeElements) {
@@ -178,6 +190,9 @@ const ZonosPayment = class {
178
190
  }
179
191
  paymentElement.mount(paymentElementContainer);
180
192
  paymentElement.on('change', event => {
193
+ if (event.complete) {
194
+ this.isPaymentInfoFilled = true;
195
+ }
181
196
  cart.stripeStore.stripePaymentEventData = event;
182
197
  });
183
198
  cart.stripeStore.stripePaymentElement = paymentElement;
@@ -188,10 +203,11 @@ const ZonosPayment = class {
188
203
  }
189
204
  render() {
190
205
  // this component loads iframe from the stripe elements and puts here, so we don't need to do anything here
191
- return (index.h(index.Host, { key: '2d664521944c4f02f34fe3130f8ebb853e562476', class: "zonos--payment zonos--elements" }, this.titleText && (index.h("zonos-text", { key: '11f683a0f6094d801103a9f04054d038b405718f', class: "zonos--title", type: "semiBoldLabel" }, this.titleText)), index.h("div", { key: '0c962441697499b3a7eb279175ce025d76d4c0fa', class: "zonos--payment-component" }), index.h("div", { key: 'a96af74f05521fcccc1912c0ec1dcbe64cfc1ae7', class: "zonos--payment-paypal-container" })));
206
+ return (index.h(index.Host, { key: '3e9f3439e139f6d040bcf8fc101f19d011debdc8', class: "zonos--payment zonos--elements" }, this.titleText && (index.h("zonos-text", { key: '2f22806f4f9380e610899a997ce9ed2bfe997be4', class: "zonos--title", type: "semiBoldLabel" }, this.titleText)), index.h("div", { key: '4d5dbd7828b3037d69adb50d4fee4ea9abf3b59b', class: "zonos--payment-component" }), index.h("div", { key: '32ee62f62a028da8481d95781a7368c60ae42614', class: "zonos--payment-paypal-container" })));
192
207
  }
193
208
  get el() { return index.getElement(this); }
194
209
  static get watchers() { return {
210
+ "isPaymentInfoFilled": ["watchIsPaymentInfoFilled"],
195
211
  "stripeElements": ["watchInitStripe"],
196
212
  "stripe": ["watchInitStripe"]
197
213
  }; }
@@ -3,12 +3,12 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  const index = require('./index-2f90486e.js');
6
- const cart = require('./cart-36799bbe.js');
6
+ const cart = require('./cart-d9052930.js');
7
7
  const zonosStore = require('./zonosStore-3812b318.js');
8
8
  const classes = require('./classes-b7918f56.js');
9
9
  const formatStringWithLinks = require('./formatStringWithLinks-52341fc7.js');
10
10
  const getHasMoreSpaceOnRight = require('./getHasMoreSpaceOnRight-4c94667f.js');
11
- require('./handleFetch-7b7f9f7c.js');
11
+ require('./handleFetch-ff25db40.js');
12
12
  require('./isDarkColor-ec4a4e7d.js');
13
13
  require('./getBorderRadius-94ef609c.js');
14
14
 
@@ -4,9 +4,9 @@ Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  const index = require('./index-2f90486e.js');
6
6
  const zonosStore = require('./zonosStore-3812b318.js');
7
- const cart = require('./cart-36799bbe.js');
7
+ const cart = require('./cart-d9052930.js');
8
8
  const classes = require('./classes-b7918f56.js');
9
- const handleFetch = require('./handleFetch-7b7f9f7c.js');
9
+ const handleFetch = require('./handleFetch-ff25db40.js');
10
10
  const getHasMoreSpaceOnRight = require('./getHasMoreSpaceOnRight-4c94667f.js');
11
11
  require('./isDarkColor-ec4a4e7d.js');
12
12
  require('./getBorderRadius-94ef609c.js');
@@ -3,10 +3,10 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  const index = require('./index-2f90486e.js');
6
- const cart = require('./cart-36799bbe.js');
6
+ const cart = require('./cart-d9052930.js');
7
7
  const zonosStore = require('./zonosStore-3812b318.js');
8
8
  const ILanguage = require('./ILanguage-98b04442.js');
9
- require('./handleFetch-7b7f9f7c.js');
9
+ require('./handleFetch-ff25db40.js');
10
10
  require('./isDarkColor-ec4a4e7d.js');
11
11
  require('./getBorderRadius-94ef609c.js');
12
12
 
@@ -232,9 +232,10 @@ export class ZonosCheckoutFinish {
232
232
  clientSecret,
233
233
  storybookForceStatus: this.storybookForceStatus,
234
234
  });
235
- this.notificationType = error ? 'error' : 'success';
235
+ const isError = status === 'requires_action' || error;
236
+ this.notificationType = isError ? 'error' : 'success';
236
237
  this.notificationMessages = messages || [];
237
- this.notificationTitle = error
238
+ this.notificationTitle = isError
238
239
  ? translate('Payment failed')
239
240
  : translate("You're all set!");
240
241
  log('=== Payment intent retrieve status', 'info', {
@@ -311,6 +312,9 @@ export class ZonosCheckoutFinish {
311
312
  // show success message right away when order id is already created
312
313
  this.isLoading = false;
313
314
  if (paypalStore.orderIdCreated) {
315
+ submitGtag('zonos-checkout-success');
316
+ // Make sure to send the event when order is completed
317
+ await trackConversionEvent('checkout_orderCompleted');
314
318
  this.notificationType = 'success';
315
319
  this.notificationTitle = translate("You're all set!");
316
320
  this.notificationMessages =
@@ -377,11 +381,11 @@ export class ZonosCheckoutFinish {
377
381
  }
378
382
  render() {
379
383
  const isTestMode = getIsTestMode();
380
- return (h(Host, { key: 'afcb0314658af4d53e7d453415dd73fb01a8f162', class: "zonos--checkout-finish zonos--elements", style: {
384
+ return (h(Host, { key: '4bb26161ad400a7bbd7b7e9f0568ac5de8f18004', class: "zonos--checkout-finish zonos--elements", style: {
381
385
  '--zonos--border-radius': getBorderRadius({
382
386
  overrideBorderStyle: this.borderRadius,
383
387
  }),
384
- } }, !this.isLoading && (h("div", { key: '99b7b6c9dd0e0545d770e4d9ed54207f5c13fdfd', class: "zonos--finish-details" }, h("div", { key: '11d249514d0eef2f8419e66b1070a20e745b84fd', class: "zonos--group" }, this.notificationType === 'success' ? (h("zonos-icon", { "aria-label": "Order success", content: SuccessIcon, iconColor: 'blue-800', size: 50 })) : (h("zonos-icon", { "aria-label": "Order failed", content: RemoveIcon, iconColor: 'red-800', size: 50 })), h("zonos-text", { key: 'c8f52780e8ea76b5951aa4ad3dfc87c19acbfd1d', class: "zonos--title", type: "semiBoldSubheader" }, this.notificationTitle), h("zonos-text", { key: '459d7c1a9bd6fd77cfda25e9500a89061874b58f', class: "zonos--subtitle", textColor: "gray-600" }, this.notificationMessages.map(message => (h(Fragment, null, message, h("br", null))))), this.shouldRenderCloseButtonForRedirectBehavior() && (h("zonos-button", { key: '4e34926ba96975ceff18016eb6bcad1906f1c773',
388
+ } }, !this.isLoading && (h("div", { key: '85d3bf11c73dfd2b18d0a6d996f2c1f4a01a2288', class: "zonos--finish-details" }, h("div", { key: '0e4fb2b7cd03a4464dde3cce69932b8482da0d02', class: "zonos--group" }, this.notificationType === 'success' ? (h("zonos-icon", { "aria-label": "Order success", content: SuccessIcon, iconColor: 'blue-800', size: 50 })) : (h("zonos-icon", { "aria-label": "Order failed", content: RemoveIcon, iconColor: 'red-800', size: 50 })), h("zonos-text", { key: '0ced9d9d83576979ae785be52c0ae07dca0fd5de', class: "zonos--title", type: "semiBoldSubheader" }, this.notificationTitle), h("zonos-text", { key: 'd14a6fbe02dc836512b41859cc8de573653c4884', class: "zonos--subtitle", textColor: "gray-600" }, this.notificationMessages.map(message => (h(Fragment, null, message, h("br", null))))), this.shouldRenderCloseButtonForRedirectBehavior() && (h("zonos-button", { key: '5a80853fd1374fc72ccc2b416b62f6c52e4916dd',
385
389
  // Only show loading spinner if it's not an error notification
386
390
  loading: this.isWaitingToRedirect &&
387
391
  this.notificationType !== 'error', onClick: () => {
@@ -393,9 +397,9 @@ export class ZonosCheckoutFinish {
393
397
  }
394
398
  this.closeClickHandler();
395
399
  }, size: "md", variant: "primary" }, translate('Close'))), !window.Zonos.isLegacyCheckout &&
396
- this.shouldRenderKeepShoppingButton() && (h("zonos-button", { key: '836907a2a325d615d897e5292f086bf9111226ae', onClick: () => this.closeClickHandler(), size: "md", variant: "primary" }, this.notificationActionText))), isTestMode &&
400
+ this.shouldRenderKeepShoppingButton() && (h("zonos-button", { key: 'ba2fca63de8f04c76fa4d1bc96d06863fbad78cf', onClick: () => this.closeClickHandler(), size: "md", variant: "primary" }, this.notificationActionText))), isTestMode &&
397
401
  cartStore.step === 'finish' &&
398
- this.notificationType === 'success' && (h("div", { key: 'ea1b4dd65f89d3eaec6391b6e440ae8ca20d5bdb', class: "zonos--finish-button-wrapper" }, h("zonos-button", { key: '350ee6b7fe58ff5e7a1584989e2df13ce5d243c6', backgroundColor: "gray-0", buttonColor: "gray-1000", onClick: () => this.closeClickHandler(), size: "lg", variant: "outline" }, "New test cart"), h("zonos-button", { key: 'd3578cef9a3f6cc69fff48ee412f7010d526c284', onClick: () => {
402
+ this.notificationType === 'success' && (h("div", { key: '1e3cb2f2f5874b93886247af585566dbaad9a45f', class: "zonos--finish-button-wrapper" }, h("zonos-button", { key: 'f8603ae4e116da9f8adabe648a6f626b994f208a', backgroundColor: "gray-0", buttonColor: "gray-1000", onClick: () => this.closeClickHandler(), size: "lg", variant: "outline" }, "New test cart"), h("zonos-button", { key: '91df622529ff650464b3694780e65d2d929548f9', onClick: () => {
399
403
  const isZonosDashboard = window.location.hostname.includes('dashboard.zonos.com');
400
404
  this.redirectToUrl(isZonosDashboard
401
405
  ? '/orders/all'