@zonos/elements 1.3.5 → 1.3.7-alpha.0

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 (411) hide show
  1. package/dist/cjs/ILanguage-d247b45b.js +26 -0
  2. package/dist/cjs/app-globals-3a1e7e63.js +5 -0
  3. package/dist/cjs/{localization-d43e1540.js → cart-ecc80eb0.js} +1086 -2
  4. package/dist/cjs/{getBorderRadius-cd7ef574.js → getBorderRadius-834c321d.js} +8 -4
  5. package/dist/cjs/index.cjs.js +0 -21
  6. package/dist/cjs/{isDarkColor-5eda1323.js → isDarkColor-924e6a7a.js} +1 -1
  7. package/dist/cjs/loader.cjs.js +5 -3
  8. package/dist/cjs/{submitGtag-bd6e9b42.js → submitGtag-907e71d3.js} +3 -3
  9. package/dist/cjs/zonos-address_4.cjs.entry.js +301 -0
  10. package/dist/cjs/zonos-badge_2.cjs.entry.js +57 -0
  11. package/dist/cjs/zonos-banner.cjs.entry.js +4 -9
  12. package/dist/cjs/{zonos-button_2.cjs.entry.js → zonos-button_3.cjs.entry.js} +42 -15
  13. package/dist/cjs/zonos-card_2.cjs.entry.js +28 -14
  14. package/dist/cjs/{zonos-cart-items_10.cjs.entry.js → zonos-cart-items_9.cjs.entry.js} +98 -99
  15. package/dist/cjs/zonos-checkout.cjs.entry.js +25 -27
  16. package/dist/cjs/zonos-component.cjs.entry.js +2 -2
  17. package/dist/cjs/zonos-controller.cjs.entry.js +29 -30
  18. package/dist/cjs/zonos-country-flag.cjs.entry.js +42 -0
  19. package/dist/cjs/{zonos-country-flag_4.cjs.entry.js → zonos-country-select_3.cjs.entry.js} +31 -56
  20. package/dist/cjs/zonos-elements.cjs.js +6 -4
  21. package/dist/cjs/zonos-hello-dialog.cjs.entry.js +29 -22
  22. package/dist/cjs/zonos-hello.cjs.entry.js +35 -33
  23. package/dist/cjs/zonos-logo.cjs.entry.js +32 -0
  24. package/dist/cjs/zonos-notification.cjs.entry.js +5 -6
  25. package/dist/cjs/zonos-payment.cjs.entry.js +6 -7
  26. package/dist/cjs/zonos-select-dialog-header_2.cjs.entry.js +45 -0
  27. package/dist/cjs/zonos-shipping-rich-radio.cjs.entry.js +4 -4
  28. package/dist/cjs/zonos-text.cjs.entry.js +4 -6
  29. package/dist/cjs/{zonosStore-b88b5671.js → zonosStore-49d4c92a.js} +5 -5
  30. package/dist/collection/collection-manifest.json +6 -1
  31. package/dist/collection/components/checkout/zonos-checkout/zonos-cart-subtotal/zonos-cart-subtotal.js +1 -1
  32. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-finish/zonos-checkout-finish.js +13 -8
  33. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-footer/assets/chevronDownIcon.svg +1 -0
  34. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-footer/assets/globe.svg +3 -0
  35. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-footer/assets/zonosIcon.svg +5 -0
  36. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-footer/zonos-checkout-footer.css +126 -0
  37. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-footer/zonos-checkout-footer.js +60 -0
  38. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-payment/zonos-checkout-payment.js +1 -1
  39. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout.css +12 -21
  40. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout.js +4 -5
  41. package/dist/collection/components/checkout/zonos-checkout/zonos-customer-info/zonos-customer-info.css +11 -1
  42. package/dist/collection/components/checkout/zonos-checkout/zonos-customer-info/zonos-customer-info.js +12 -4
  43. package/dist/collection/components/checkout/zonos-checkout/zonos-review/zonos-review.js +3 -3
  44. package/dist/collection/components/checkout/zonos-checkout/zonos-shipping/zonos-shipping.js +1 -1
  45. package/dist/collection/components/common/zonos-badge/zonos-badge.js +7 -26
  46. package/dist/collection/components/common/zonos-banner/zonos-banner.js +2 -25
  47. package/dist/collection/components/common/zonos-button/zonos-button.css +18 -0
  48. package/dist/collection/components/common/zonos-button/zonos-button.js +9 -28
  49. package/dist/collection/components/common/zonos-card/zonos-card.js +2 -20
  50. package/dist/collection/components/common/zonos-checkbox/zonos-checkbox.css +82 -0
  51. package/dist/collection/components/common/zonos-checkbox/zonos-checkbox.js +218 -0
  52. package/dist/collection/components/common/zonos-collapse/zonos-collapse.js +15 -2
  53. package/dist/collection/components/common/zonos-country-flag/zonos-country-flag.js +1 -20
  54. package/dist/collection/components/common/zonos-country-select/assets/greenCheckDuotone.svg +4 -0
  55. package/dist/collection/components/common/zonos-country-select/zonos-country-select.css +11 -10
  56. package/dist/collection/components/common/zonos-country-select/zonos-country-select.js +7 -11
  57. package/dist/collection/components/common/zonos-custom-message/zonos-custom-message.js +2 -2
  58. package/dist/collection/components/common/zonos-dialog/zonos-dialog.js +3 -3
  59. package/dist/collection/components/common/zonos-icon/zonos-icon.js +4 -4
  60. package/dist/collection/components/common/zonos-language-select/assets/greenCheckDuotone.svg +4 -0
  61. package/dist/collection/components/common/zonos-language-select/zonos-language-select.css +61 -0
  62. package/dist/collection/components/common/zonos-language-select/zonos-language-select.js +58 -0
  63. package/dist/collection/components/common/zonos-logo/zonos-logo.js +2 -21
  64. package/dist/collection/components/common/zonos-notification/zonos-notification.js +3 -26
  65. package/dist/collection/components/common/zonos-select-dialog-header/assets/removeIcon.svg +1 -0
  66. package/dist/collection/components/common/zonos-select-dialog-header/zonos-select-dialog-header.css +45 -0
  67. package/dist/collection/components/common/zonos-select-dialog-header/zonos-select-dialog-header.js +68 -0
  68. package/dist/collection/components/common/zonos-shipping-rich-radio/zonos-shipping-rich-radio.js +1 -1
  69. package/dist/collection/components/common/zonos-spinner/zonos-spinner.js +4 -4
  70. package/dist/collection/components/common/zonos-text/zonos-text.js +4 -24
  71. package/dist/collection/components/common/zonos-tooltip/zonos-tooltip.css +55 -0
  72. package/dist/collection/components/common/zonos-tooltip/zonos-tooltip.js +72 -0
  73. package/dist/collection/components/common/zonos-v-stack/zonos-v-stack.js +2 -21
  74. package/dist/collection/components/component-template/zonos-component/zonos-component.js +1 -1
  75. package/dist/collection/components/hello/zonos-hello-dialog/zonos-hello-dialog-footer/assets/globe.svg +3 -0
  76. package/dist/collection/components/hello/zonos-hello-dialog/zonos-hello-dialog-footer/zonos-hello-dialog-footer.css +10 -0
  77. package/dist/collection/components/hello/zonos-hello-dialog/zonos-hello-dialog-footer/zonos-hello-dialog-footer.js +27 -5
  78. package/dist/collection/components/hello/zonos-hello-dialog/zonos-hello-dialog.css +16 -2
  79. package/dist/collection/components/hello/zonos-hello-dialog/zonos-hello-dialog.js +11 -5
  80. package/dist/collection/components/main/zonos-controller.js +1 -1
  81. package/dist/collection/components/store/checkout/stripe.js +31 -7
  82. package/dist/collection/components/store/hello/localization.js +32 -2
  83. package/dist/collection/components/store/translationStore/strings.arabic.js +18 -0
  84. package/dist/collection/components/store/translationStore/strings.base.js +18 -0
  85. package/dist/collection/components/store/translationStore/strings.chinese.js +18 -0
  86. package/dist/collection/components/store/translationStore/strings.danish.js +18 -0
  87. package/dist/collection/components/store/translationStore/strings.dutch.js +18 -0
  88. package/dist/collection/components/store/translationStore/strings.french.js +18 -0
  89. package/dist/collection/components/store/translationStore/strings.german.js +18 -0
  90. package/dist/collection/components/store/translationStore/strings.hebrew.js +18 -0
  91. package/dist/collection/components/store/translationStore/strings.indonesian.js +18 -0
  92. package/dist/collection/components/store/translationStore/strings.italian.js +18 -0
  93. package/dist/collection/components/store/translationStore/strings.japanese.js +18 -0
  94. package/dist/collection/components/store/translationStore/strings.korean.js +18 -0
  95. package/dist/collection/components/store/translationStore/strings.norwegian.js +18 -0
  96. package/dist/collection/components/store/translationStore/strings.polish.js +18 -0
  97. package/dist/collection/components/store/translationStore/strings.portuguese.js +18 -0
  98. package/dist/collection/components/store/translationStore/strings.russian.js +18 -0
  99. package/dist/collection/components/store/translationStore/strings.spanish.js +18 -0
  100. package/dist/collection/components/store/translationStore/strings.swedish.js +18 -0
  101. package/dist/collection/components/store/translationStore/strings.turkish.js +18 -0
  102. package/dist/collection/components/store/translationStore/strings.vietnamese.js +18 -0
  103. package/dist/collection/components/store/zonosStore.js +4 -4
  104. package/dist/collection/components/stripe/zonos-address/zonos-address.js +63 -24
  105. package/dist/collection/components/stripe/zonos-link-authentication/zonos-link-authentication.js +1 -1
  106. package/dist/collection/components/stripe/zonos-payment/zonos-payment.js +1 -1
  107. package/dist/collection/components/utils/api/prepCalculateLandedCost.js +19 -1
  108. package/dist/collection/components/utils/api/triggerBuildLandedCost.js +11 -5
  109. package/dist/collection/components/utils/getBorderRadius.js +7 -3
  110. package/dist/collection/types/ILanguage.js +22 -0
  111. package/dist/collection/types/generated/graphql.customer.types.js +19 -0
  112. package/dist/collection/types/index.js +0 -1
  113. package/dist/collection/types/styles/Color.js +9 -0
  114. package/dist/components/ILanguage.js +24 -0
  115. package/dist/components/getBorderRadius.js +7 -3
  116. package/dist/components/index.js +0 -1
  117. package/dist/components/isDarkColor.js +1 -1
  118. package/dist/components/{localization.js → stripe.js} +1070 -2
  119. package/dist/components/submitGtag.js +1 -1
  120. package/dist/components/zonos-address2.js +64 -26
  121. package/dist/components/zonos-badge2.js +8 -10
  122. package/dist/components/zonos-banner2.js +3 -9
  123. package/dist/components/zonos-button2.js +10 -12
  124. package/dist/components/zonos-card2.js +3 -5
  125. package/dist/components/zonos-cart-items2.js +1 -1
  126. package/dist/components/zonos-cart-subtotal2.js +14 -9
  127. package/dist/components/zonos-checkbox.d.ts +11 -0
  128. package/dist/components/zonos-checkbox.js +6 -0
  129. package/dist/components/zonos-checkbox2.js +87 -0
  130. package/dist/components/zonos-checkout-finish2.js +15 -7
  131. package/dist/components/zonos-checkout-footer.d.ts +11 -0
  132. package/dist/components/zonos-checkout-footer.js +6 -0
  133. package/dist/components/zonos-checkout-footer2.js +109 -0
  134. package/dist/components/zonos-checkout-payment2.js +2 -3
  135. package/dist/components/zonos-checkout.js +74 -52
  136. package/dist/components/zonos-collapse2.js +16 -3
  137. package/dist/components/zonos-component.js +1 -1
  138. package/dist/components/zonos-controller.js +3 -4
  139. package/dist/components/zonos-country-flag2.js +3 -5
  140. package/dist/components/zonos-country-select2.js +26 -19
  141. package/dist/components/zonos-custom-message2.js +3 -3
  142. package/dist/components/zonos-customer-info2.js +30 -11
  143. package/dist/components/zonos-dialog2.js +4 -4
  144. package/dist/components/zonos-hello-dialog-footer2.js +23 -10
  145. package/dist/components/zonos-hello-dialog2.js +41 -23
  146. package/dist/components/zonos-hello.js +31 -19
  147. package/dist/components/zonos-icon2.js +4 -4
  148. package/dist/components/zonos-language-select.d.ts +11 -0
  149. package/dist/components/zonos-language-select.js +6 -0
  150. package/dist/components/zonos-language-select2.js +87 -0
  151. package/dist/components/zonos-link-authentication2.js +2 -2
  152. package/dist/components/zonos-logo.js +44 -1
  153. package/dist/components/zonos-notification2.js +4 -6
  154. package/dist/components/zonos-payment2.js +2 -2
  155. package/dist/components/zonos-review2.js +4 -5
  156. package/dist/components/zonos-select-dialog-header.d.ts +11 -0
  157. package/dist/components/zonos-select-dialog-header.js +6 -0
  158. package/dist/components/zonos-select-dialog-header2.js +71 -0
  159. package/dist/components/zonos-shipping-rich-radio2.js +2 -2
  160. package/dist/components/zonos-shipping2.js +2 -3
  161. package/dist/components/zonos-spinner2.js +3 -3
  162. package/dist/components/zonos-text2.js +4 -7
  163. package/dist/components/zonos-tooltip.d.ts +11 -0
  164. package/dist/components/zonos-tooltip.js +6 -0
  165. package/dist/components/zonos-tooltip2.js +48 -0
  166. package/dist/components/zonos-v-stack2.js +4 -6
  167. package/dist/components/zonosStore.js +5 -5
  168. package/dist/esm/ILanguage-97790bee.js +24 -0
  169. package/dist/esm/app-globals-0f993ce5.js +3 -0
  170. package/dist/esm/{localization-5d83fde2.js → cart-2a0a6871.js} +1071 -3
  171. package/dist/esm/getBorderRadius-0c7dfcf0.js +20 -0
  172. package/dist/esm/index.js +1 -6
  173. package/dist/esm/{isDarkColor-8696cb70.js → isDarkColor-d0a57fd2.js} +1 -1
  174. package/dist/esm/loader.js +6 -4
  175. package/dist/esm/{submitGtag-776c5e10.js → submitGtag-a38aed23.js} +2 -2
  176. package/dist/esm/zonos-address_4.entry.js +294 -0
  177. package/dist/esm/zonos-badge_2.entry.js +52 -0
  178. package/dist/esm/zonos-banner.entry.js +4 -9
  179. package/dist/esm/{zonos-button_2.entry.js → zonos-button_3.entry.js} +42 -16
  180. package/dist/esm/zonos-card_2.entry.js +28 -14
  181. package/dist/esm/{zonos-cart-items_10.entry.js → zonos-cart-items_9.entry.js} +86 -86
  182. package/dist/esm/zonos-checkout.entry.js +11 -13
  183. package/dist/esm/zonos-component.entry.js +2 -2
  184. package/dist/esm/zonos-controller.entry.js +6 -7
  185. package/dist/esm/zonos-country-flag.entry.js +38 -0
  186. package/dist/esm/{zonos-country-flag_4.entry.js → zonos-country-select_3.entry.js} +31 -55
  187. package/dist/esm/zonos-elements.js +7 -5
  188. package/dist/esm/zonos-hello-dialog.entry.js +15 -8
  189. package/dist/esm/zonos-hello.entry.js +5 -3
  190. package/dist/esm/zonos-logo.entry.js +28 -0
  191. package/dist/esm/zonos-notification.entry.js +5 -6
  192. package/dist/esm/zonos-payment.entry.js +6 -7
  193. package/dist/esm/zonos-select-dialog-header_2.entry.js +40 -0
  194. package/dist/esm/zonos-shipping-rich-radio.entry.js +4 -4
  195. package/dist/esm/zonos-text.entry.js +4 -6
  196. package/dist/esm/{zonosStore-e59617f8.js → zonosStore-dec6bd7e.js} +5 -5
  197. package/dist/esm-es5/ILanguage-97790bee.js +1 -0
  198. package/dist/esm-es5/app-globals-0f993ce5.js +1 -0
  199. package/dist/esm-es5/cart-2a0a6871.js +1 -0
  200. package/dist/esm-es5/getBorderRadius-0c7dfcf0.js +1 -0
  201. package/dist/esm-es5/index.js +0 -1
  202. package/dist/esm-es5/{isDarkColor-8696cb70.js → isDarkColor-d0a57fd2.js} +1 -1
  203. package/dist/esm-es5/loader.js +1 -1
  204. package/dist/esm-es5/submitGtag-a38aed23.js +1 -0
  205. package/dist/esm-es5/zonos-address_4.entry.js +1 -0
  206. package/dist/esm-es5/zonos-badge_2.entry.js +1 -0
  207. package/dist/esm-es5/zonos-banner.entry.js +1 -1
  208. package/dist/esm-es5/zonos-button_3.entry.js +1 -0
  209. package/dist/esm-es5/zonos-card_2.entry.js +1 -1
  210. package/dist/esm-es5/zonos-cart-items_9.entry.js +1 -0
  211. package/dist/esm-es5/zonos-checkout.entry.js +1 -1
  212. package/dist/esm-es5/zonos-component.entry.js +1 -1
  213. package/dist/esm-es5/zonos-controller.entry.js +1 -1
  214. package/dist/esm-es5/zonos-country-flag.entry.js +1 -0
  215. package/dist/esm-es5/zonos-country-select_3.entry.js +1 -0
  216. package/dist/esm-es5/zonos-elements.js +1 -1
  217. package/dist/esm-es5/zonos-hello-dialog.entry.js +1 -1
  218. package/dist/esm-es5/zonos-hello.entry.js +1 -1
  219. package/dist/esm-es5/zonos-logo.entry.js +1 -0
  220. package/dist/esm-es5/zonos-notification.entry.js +1 -1
  221. package/dist/esm-es5/zonos-payment.entry.js +1 -1
  222. package/dist/esm-es5/zonos-select-dialog-header_2.entry.js +1 -0
  223. package/dist/esm-es5/zonos-shipping-rich-radio.entry.js +1 -1
  224. package/dist/esm-es5/zonos-text.entry.js +1 -1
  225. package/dist/esm-es5/{zonosStore-e59617f8.js → zonosStore-dec6bd7e.js} +1 -1
  226. package/dist/scripts/insertTranslations.js +1 -0
  227. package/dist/scripts/loadZonos.js +1 -1
  228. package/dist/scripts/zonos.js +1 -1
  229. package/dist/scripts/zonosBase.js +1 -1
  230. package/dist/types/components/checkout/zonos-checkout/zonos-checkout-finish/zonos-checkout-finish.d.ts +2 -1
  231. package/dist/types/components/checkout/zonos-checkout/zonos-checkout-footer/zonos-checkout-footer.d.ts +7 -0
  232. package/dist/types/components/common/zonos-badge/zonos-badge.d.ts +1 -5
  233. package/dist/types/components/common/zonos-banner/zonos-banner.d.ts +0 -4
  234. package/dist/types/components/common/zonos-button/zonos-button.d.ts +1 -5
  235. package/dist/types/components/common/zonos-card/zonos-card.d.ts +0 -4
  236. package/dist/types/components/common/zonos-checkbox/zonos-checkbox.d.ts +42 -0
  237. package/dist/types/components/common/zonos-country-flag/zonos-country-flag.d.ts +0 -4
  238. package/dist/types/components/common/zonos-country-select/zonos-country-select.d.ts +1 -1
  239. package/dist/types/components/common/zonos-icon/zonos-icon.d.ts +1 -1
  240. package/dist/types/components/common/zonos-language-select/zonos-language-select.d.ts +9 -0
  241. package/dist/types/components/common/zonos-logo/zonos-logo.d.ts +0 -4
  242. package/dist/types/components/common/zonos-notification/zonos-notification.d.ts +0 -4
  243. package/dist/types/components/common/zonos-select-dialog-header/zonos-select-dialog-header.d.ts +12 -0
  244. package/dist/types/components/common/zonos-spinner/zonos-spinner.d.ts +1 -1
  245. package/dist/types/components/common/zonos-text/zonos-text.d.ts +1 -5
  246. package/dist/types/components/common/zonos-tooltip/zonos-tooltip.d.ts +12 -0
  247. package/dist/types/components/common/zonos-v-stack/zonos-v-stack.d.ts +0 -4
  248. package/dist/types/components/hello/zonos-hello-dialog/zonos-hello-dialog-footer/zonos-hello-dialog-footer.d.ts +5 -0
  249. package/dist/types/components/hello/zonos-hello-dialog/zonos-hello-dialog.d.ts +2 -0
  250. package/dist/types/components/store/checkout/stripe.d.ts +12 -0
  251. package/dist/types/components/store/hello/localization.d.ts +2 -1
  252. package/dist/types/components/store/translationStore/strings.arabic.d.ts +18 -0
  253. package/dist/types/components/store/translationStore/strings.base.d.ts +18 -0
  254. package/dist/types/components/store/translationStore/strings.chinese.d.ts +18 -0
  255. package/dist/types/components/store/translationStore/strings.danish.d.ts +18 -0
  256. package/dist/types/components/store/translationStore/strings.dutch.d.ts +18 -0
  257. package/dist/types/components/store/translationStore/strings.french.d.ts +18 -0
  258. package/dist/types/components/store/translationStore/strings.german.d.ts +18 -0
  259. package/dist/types/components/store/translationStore/strings.hebrew.d.ts +18 -0
  260. package/dist/types/components/store/translationStore/strings.indonesian.d.ts +18 -0
  261. package/dist/types/components/store/translationStore/strings.italian.d.ts +18 -0
  262. package/dist/types/components/store/translationStore/strings.japanese.d.ts +18 -0
  263. package/dist/types/components/store/translationStore/strings.korean.d.ts +18 -0
  264. package/dist/types/components/store/translationStore/strings.norwegian.d.ts +18 -0
  265. package/dist/types/components/store/translationStore/strings.polish.d.ts +18 -0
  266. package/dist/types/components/store/translationStore/strings.portuguese.d.ts +18 -0
  267. package/dist/types/components/store/translationStore/strings.russian.d.ts +18 -0
  268. package/dist/types/components/store/translationStore/strings.spanish.d.ts +18 -0
  269. package/dist/types/components/store/translationStore/strings.swedish.d.ts +18 -0
  270. package/dist/types/components/store/translationStore/strings.turkish.d.ts +18 -0
  271. package/dist/types/components/store/translationStore/strings.vietnamese.d.ts +18 -0
  272. package/dist/types/components/store/zonosStore.d.ts +1 -1
  273. package/dist/types/components/stripe/zonos-address/zonos-address.d.ts +3 -0
  274. package/dist/types/components/utils/api/triggerBuildLandedCost.d.ts +18 -2
  275. package/dist/types/components/utils/changeDeepProperty.d.ts +1 -1
  276. package/dist/types/components/utils/changeDeepPropertyAtIndex.d.ts +1 -1
  277. package/dist/types/components/utils/getBorderRadius.d.ts +1 -1
  278. package/dist/types/components/utils/hello/currencyConversion/getLanguageCode.d.ts +1 -1
  279. package/dist/types/components.d.ts +242 -116
  280. package/dist/types/types/ICountryJson.d.ts +2 -1
  281. package/dist/types/types/ILanguage.d.ts +81 -0
  282. package/dist/types/types/checkout/CheckoutConfig.d.ts +3 -3
  283. package/dist/types/types/checkout/api/CalculateLandedCostRequest.d.ts +13 -0
  284. package/dist/types/types/generated/graphql.customer.types.d.ts +31 -4
  285. package/dist/types/types/generated/graphql.customer.types.ts +45 -4
  286. package/dist/types/types/generated/graphql.frontend.types.d.ts +5 -5
  287. package/dist/types/types/generated/graphql.frontend.types.ts +13 -3
  288. package/dist/types/types/index.d.ts +1 -1
  289. package/dist/types/types/styles/Color.d.ts +2 -0
  290. package/dist/zonos-elements/index.esm.js +0 -1
  291. package/dist/zonos-elements/p-0057e374.entry.js +1 -0
  292. package/dist/zonos-elements/{p-120df5be.system.entry.js → p-06652d87.system.entry.js} +1 -1
  293. package/dist/zonos-elements/p-066c5893.system.js +1 -0
  294. package/dist/zonos-elements/p-0c72fb79.system.entry.js +1 -0
  295. package/dist/zonos-elements/p-16ad90ca.js +1 -0
  296. package/dist/zonos-elements/p-1f85a98c.system.entry.js +1 -0
  297. package/dist/zonos-elements/p-290c3670.entry.js +1 -0
  298. package/dist/zonos-elements/p-2d2e1831.entry.js +1 -0
  299. package/dist/zonos-elements/p-2f1e1cbb.system.entry.js +1 -0
  300. package/dist/zonos-elements/p-33080cde.system.entry.js +1 -0
  301. package/dist/zonos-elements/{p-0024f8c2.js → p-34c03be2.js} +1 -1
  302. package/dist/zonos-elements/p-34efed1d.entry.js +1 -0
  303. package/dist/zonos-elements/p-375c472a.system.entry.js +1 -0
  304. package/dist/zonos-elements/p-50ea2036.system.js +1 -0
  305. package/dist/zonos-elements/p-549c181b.system.js +1 -0
  306. package/dist/zonos-elements/{p-be23cc91.system.entry.js → p-55970b10.system.entry.js} +1 -1
  307. package/dist/zonos-elements/p-561e44d6.entry.js +1 -0
  308. package/dist/zonos-elements/p-56ba5cbf.system.js +1 -0
  309. package/dist/zonos-elements/{p-dc09ca69.system.js → p-591eb6dd.system.js} +1 -1
  310. package/dist/zonos-elements/p-5b44abc8.system.js +1 -0
  311. package/dist/zonos-elements/p-5c4dc123.js +1 -0
  312. package/dist/zonos-elements/p-656c836b.entry.js +1 -0
  313. package/dist/zonos-elements/p-67737613.system.entry.js +1 -0
  314. package/dist/zonos-elements/p-79b910bf.system.entry.js +1 -0
  315. package/dist/zonos-elements/p-7d1d862f.system.entry.js +1 -0
  316. package/dist/zonos-elements/{p-5a0264e8.system.entry.js → p-88a55076.system.entry.js} +1 -1
  317. package/dist/zonos-elements/p-8aeb4679.system.entry.js +1 -0
  318. package/dist/zonos-elements/p-8d645a00.entry.js +1 -0
  319. package/dist/zonos-elements/p-9878a770.js +1 -0
  320. package/dist/zonos-elements/p-a219689f.entry.js +1 -0
  321. package/dist/zonos-elements/p-a3d72a33.entry.js +1 -0
  322. package/dist/zonos-elements/{p-aca66e4b.entry.js → p-a4de3fb2.entry.js} +1 -1
  323. package/dist/zonos-elements/p-a93c594f.entry.js +1 -0
  324. package/dist/zonos-elements/p-a95c034c.entry.js +1 -0
  325. package/dist/zonos-elements/p-abe7524f.system.js +1 -0
  326. package/dist/zonos-elements/p-afe40057.entry.js +1 -0
  327. package/dist/zonos-elements/p-b10ff468.entry.js +1 -0
  328. package/dist/zonos-elements/p-b6992dc2.system.entry.js +1 -0
  329. package/dist/zonos-elements/{p-af910392.js → p-bce46c41.js} +1 -1
  330. package/dist/zonos-elements/p-c56d4a44.entry.js +1 -0
  331. package/dist/zonos-elements/p-c7098c3b.entry.js +1 -0
  332. package/dist/zonos-elements/{p-ead79548.system.js → p-cbb1e700.system.js} +1 -1
  333. package/dist/zonos-elements/p-cc63a29f.system.entry.js +1 -0
  334. package/dist/zonos-elements/p-cd8bd5e9.system.entry.js +1 -0
  335. package/dist/zonos-elements/p-d36faf87.system.entry.js +1 -0
  336. package/dist/zonos-elements/p-dfd3edcf.entry.js +1 -0
  337. package/dist/zonos-elements/p-e1255160.js +1 -0
  338. package/dist/zonos-elements/p-e161a08c.entry.js +1 -0
  339. package/dist/zonos-elements/p-e2770968.system.entry.js +1 -0
  340. package/dist/zonos-elements/p-e2c6ad57.entry.js +1 -0
  341. package/dist/zonos-elements/{p-73174d0c.system.entry.js → p-e855966f.system.entry.js} +1 -1
  342. package/dist/zonos-elements/p-ea93943a.system.entry.js +1 -0
  343. package/dist/zonos-elements/{p-7f68c103.system.js → p-ec4d08b3.system.js} +1 -1
  344. package/dist/zonos-elements/{p-e8da4463.js → p-f455e08c.js} +1 -1
  345. package/dist/zonos-elements/zonos-elements.esm.js +1 -1
  346. package/dist/zonos-elements/zonos-elements.js +1 -1
  347. package/package.json +17 -18
  348. package/dist/cjs/cart-c1b0915c.js +0 -655
  349. package/dist/cjs/zonos-address_2.cjs.entry.js +0 -161
  350. package/dist/cjs/zonos-badge.cjs.entry.js +0 -38
  351. package/dist/cjs/zonos-icon.cjs.entry.js +0 -35
  352. package/dist/collection/components/common/zonos-country-select/assets/arrowLeftBlue.svg +0 -1
  353. package/dist/components/cart.js +0 -637
  354. package/dist/components/zonos-logo2.js +0 -48
  355. package/dist/esm/cart-7e7c7585.js +0 -637
  356. package/dist/esm/getBorderRadius-9e4cb3b1.js +0 -16
  357. package/dist/esm/zonos-address_2.entry.js +0 -156
  358. package/dist/esm/zonos-badge.entry.js +0 -34
  359. package/dist/esm/zonos-icon.entry.js +0 -31
  360. package/dist/esm-es5/cart-7e7c7585.js +0 -1
  361. package/dist/esm-es5/getBorderRadius-9e4cb3b1.js +0 -1
  362. package/dist/esm-es5/localization-5d83fde2.js +0 -1
  363. package/dist/esm-es5/submitGtag-776c5e10.js +0 -1
  364. package/dist/esm-es5/zonos-address_2.entry.js +0 -1
  365. package/dist/esm-es5/zonos-badge.entry.js +0 -1
  366. package/dist/esm-es5/zonos-button_2.entry.js +0 -1
  367. package/dist/esm-es5/zonos-cart-items_10.entry.js +0 -1
  368. package/dist/esm-es5/zonos-country-flag_4.entry.js +0 -1
  369. package/dist/esm-es5/zonos-icon.entry.js +0 -1
  370. package/dist/zonos-elements/p-027abb50.entry.js +0 -1
  371. package/dist/zonos-elements/p-09c5dc1b.system.entry.js +0 -1
  372. package/dist/zonos-elements/p-1156ae5d.system.entry.js +0 -1
  373. package/dist/zonos-elements/p-12ecf765.system.js +0 -1
  374. package/dist/zonos-elements/p-174239da.system.js +0 -1
  375. package/dist/zonos-elements/p-18e09138.system.entry.js +0 -1
  376. package/dist/zonos-elements/p-1c00ffea.system.entry.js +0 -1
  377. package/dist/zonos-elements/p-21793192.entry.js +0 -1
  378. package/dist/zonos-elements/p-2589a038.system.entry.js +0 -1
  379. package/dist/zonos-elements/p-28d7b75d.entry.js +0 -1
  380. package/dist/zonos-elements/p-31fa76da.entry.js +0 -1
  381. package/dist/zonos-elements/p-3319e4db.entry.js +0 -1
  382. package/dist/zonos-elements/p-357f0c61.entry.js +0 -1
  383. package/dist/zonos-elements/p-410045c5.system.entry.js +0 -1
  384. package/dist/zonos-elements/p-4d0861e9.system.js +0 -1
  385. package/dist/zonos-elements/p-54ef8ff3.entry.js +0 -1
  386. package/dist/zonos-elements/p-626b5a52.system.entry.js +0 -1
  387. package/dist/zonos-elements/p-6444a4b9.entry.js +0 -1
  388. package/dist/zonos-elements/p-65f4af1a.system.entry.js +0 -1
  389. package/dist/zonos-elements/p-661bc488.entry.js +0 -1
  390. package/dist/zonos-elements/p-6c47083f.entry.js +0 -1
  391. package/dist/zonos-elements/p-6d454281.entry.js +0 -1
  392. package/dist/zonos-elements/p-7748735d.entry.js +0 -1
  393. package/dist/zonos-elements/p-78886ed6.system.entry.js +0 -1
  394. package/dist/zonos-elements/p-8ebc0b64.js +0 -1
  395. package/dist/zonos-elements/p-a6f2e282.system.js +0 -1
  396. package/dist/zonos-elements/p-b035f9e5.system.js +0 -1
  397. package/dist/zonos-elements/p-b1ffb37b.entry.js +0 -1
  398. package/dist/zonos-elements/p-b58d2231.entry.js +0 -1
  399. package/dist/zonos-elements/p-bd02a65c.entry.js +0 -1
  400. package/dist/zonos-elements/p-bea31a7b.system.entry.js +0 -1
  401. package/dist/zonos-elements/p-cfe4a318.js +0 -1
  402. package/dist/zonos-elements/p-e4a2a1b0.system.entry.js +0 -1
  403. package/dist/zonos-elements/p-eb631432.system.entry.js +0 -1
  404. package/dist/zonos-elements/p-f2733cc7.js +0 -1
  405. package/dist/zonos-elements/p-f342e7c7.entry.js +0 -1
  406. package/dist/zonos-elements/p-f82e000f.system.entry.js +0 -1
  407. /package/dist/cjs/{index-3ead02fe.js → index-72767498.js} +0 -0
  408. /package/dist/esm/{index-81a199ef.js → index-b5be4dc3.js} +0 -0
  409. /package/dist/esm-es5/{index-81a199ef.js → index-b5be4dc3.js} +0 -0
  410. /package/dist/zonos-elements/{p-4d8545e1.js → p-58127116.js} +0 -0
  411. /package/dist/zonos-elements/{p-4d39efb6.system.js → p-d1ab0823.system.js} +0 -0
@@ -1,5 +1,5 @@
1
1
  import { z as zonosStore } from './zonosStore.js';
2
- import { a as log } from './localization.js';
2
+ import { d as log } from './stripe.js';
3
3
 
4
4
  /**
5
5
  * Submit a gtag event if the gtag function is available.
@@ -1,6 +1,5 @@
1
1
  import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
2
- import { s as stripeStore, k as stripeStorePrefetchLandedCost } from './cart.js';
3
- import { l as logError, b as localizationStore } from './localization.js';
2
+ import { s as stripeStore, a as stripeStorePrefetchLandedCost, l as logError, b as localizationStore } from './stripe.js';
4
3
  import { i as isCheckoutMobile } from './isCheckoutMobile.js';
5
4
  import { d as defineCustomElement$1 } from './zonos-text2.js';
6
5
 
@@ -15,13 +14,46 @@ const ZonosAddress = /*@__PURE__*/ proxyCustomElement(class ZonosAddress extends
15
14
  this.titleText = undefined;
16
15
  this.defaultAddress = null;
17
16
  this.stripe = window.Zonos.stripe;
18
- this.isDirtyAddress = !!stripeStore.stripeAddressEventData &&
19
- stripeStore.stripeAddressEventData.value.address.line1.length > 0;
17
+ this.isDirtyAddress = false;
18
+ }
19
+ getStripeAddressInstance() {
20
+ if (this.type === 'billing') {
21
+ return {
22
+ stripeAddressElement: stripeStore.stripeBillingAddressElement,
23
+ stripeAddressEventData: stripeStore.stripeBillingAddressEventData,
24
+ stripeElements: stripeStore.stripeElementsForBillingAddress,
25
+ };
26
+ }
27
+ return {
28
+ stripeAddressElement: stripeStore.stripeAddressElement,
29
+ stripeAddressEventData: stripeStore.stripeAddressEventData,
30
+ stripeElements: stripeStore.stripeElements,
31
+ };
32
+ }
33
+ updateAddressEventData({ event, type, }) {
34
+ switch (type) {
35
+ case 'billing':
36
+ stripeStore.stripeBillingAddressEventData = event;
37
+ break;
38
+ default:
39
+ stripeStore.stripeAddressEventData = event;
40
+ break;
41
+ }
42
+ // only prefetch if the address type is shipping
43
+ void stripeStorePrefetchLandedCost();
44
+ }
45
+ updateAddressElement({ stripeAddressElement, type, }) {
46
+ if (type === 'shipping') {
47
+ stripeStore.stripeAddressElement = stripeAddressElement;
48
+ return;
49
+ }
50
+ stripeStore.stripeBillingAddressElement = stripeAddressElement;
20
51
  }
21
52
  async watchInitStripe() {
22
- var _a, _b, _c, _d, _e, _f, _g;
53
+ var _a, _b;
23
54
  this.stripe = window.Zonos.stripe;
24
- if (!this.stripe || !stripeStore.stripeElements) {
55
+ const { stripeAddressEventData, stripeElements } = this.getStripeAddressInstance();
56
+ if (!this.stripe || !stripeElements) {
25
57
  logError("Stripe is not initialized. Couldn't load stripe element.");
26
58
  return;
27
59
  }
@@ -32,21 +64,19 @@ const ZonosAddress = /*@__PURE__*/ proxyCustomElement(class ZonosAddress extends
32
64
  (_b = this.defaultAddress) === null || _b === void 0 ? true : delete _b.phone;
33
65
  }
34
66
  const shippableCountries = localizationStore.shippingZoneCountries;
35
- const addressElement = stripeStore.stripeElements.create('address', {
36
- allowedCountries: shippableCountries
37
- ? Object.values(shippableCountries).map(country => country.code)
38
- : [],
39
- autocomplete: {
40
- mode: 'automatic',
41
- },
67
+ const shippingZone = shippableCountries
68
+ ? Object.values(shippableCountries).map(country => country.code)
69
+ : [];
70
+ const addressElement = stripeElements.create('address', {
71
+ allowedCountries: this.type === 'shipping' ? shippingZone : [],
42
72
  contacts: this.defaultAddress ? [this.defaultAddress] : [],
43
73
  defaultValues: {
44
- address: Object.assign(Object.assign({}, (_c = stripeStore.stripeAddressEventData) === null || _c === void 0 ? void 0 : _c.value.address), { country: ((_d = stripeStore.stripeAddressEventData) === null || _d === void 0 ? void 0 : _d.value.address.country) ||
74
+ address: Object.assign(Object.assign({}, stripeAddressEventData === null || stripeAddressEventData === void 0 ? void 0 : stripeAddressEventData.value.address), { country: (stripeAddressEventData === null || stripeAddressEventData === void 0 ? void 0 : stripeAddressEventData.value.address.country) ||
45
75
  localizationStore.selectedCountryCode ||
46
76
  'AL' }),
47
- firstName: (_e = stripeStore.stripeAddressEventData) === null || _e === void 0 ? void 0 : _e.value.firstName,
48
- lastName: (_f = stripeStore.stripeAddressEventData) === null || _f === void 0 ? void 0 : _f.value.lastName,
49
- phone: (_g = stripeStore.stripeAddressEventData) === null || _g === void 0 ? void 0 : _g.value.phone,
77
+ firstName: stripeAddressEventData === null || stripeAddressEventData === void 0 ? void 0 : stripeAddressEventData.value.firstName,
78
+ lastName: stripeAddressEventData === null || stripeAddressEventData === void 0 ? void 0 : stripeAddressEventData.value.lastName,
79
+ phone: stripeAddressEventData === null || stripeAddressEventData === void 0 ? void 0 : stripeAddressEventData.value.phone,
50
80
  },
51
81
  display: {
52
82
  name: 'split',
@@ -74,31 +104,39 @@ const ZonosAddress = /*@__PURE__*/ proxyCustomElement(class ZonosAddress extends
74
104
  }
75
105
  else {
76
106
  // scroll into the end of the page so the address placeholder won't be hidden
77
- const yOffset = 100;
107
+ const yOffset = this.type === 'shipping' ? 100 : 600;
78
108
  const parentWrapper = this.el.closest('.zonos--group');
79
109
  const y = this.el.getBoundingClientRect().top + yOffset;
80
110
  parentWrapper === null || parentWrapper === void 0 ? void 0 : parentWrapper.scrollTo({ behavior: 'smooth', top: y });
81
111
  }
82
- }, 400);
112
+ }, 600);
83
113
  }
84
- stripeStore.stripeAddressEventData = Object.assign(Object.assign({}, event), { elementMode: 'shipping', elementType: 'address', empty: false, value: Object.assign(Object.assign({}, eventValue), { firstName: eventValue.firstName || eventValue.name.split(' ')[0], lastName: eventValue.lastName || eventValue.name.split(' ').pop() }) });
85
- // run prefetch landed cost when address is changed
86
- void stripeStorePrefetchLandedCost();
114
+ this.updateAddressEventData({
115
+ event: Object.assign(Object.assign({}, event), { elementMode: this.type, elementType: 'address', empty: false, value: Object.assign(Object.assign({}, eventValue), { firstName: eventValue.firstName || eventValue.name.split(' ')[0], lastName: eventValue.lastName || eventValue.name.split(' ').pop() }) }),
116
+ type: this.type,
117
+ });
118
+ });
119
+ this.updateAddressElement({
120
+ stripeAddressElement: addressElement,
121
+ type: this.type,
87
122
  });
88
- stripeStore.stripeAddressElement = addressElement;
89
123
  }
90
124
  disconnectedCallback() {
91
- var _a;
92
125
  // destroy the stripe element when this component is removed from the DOM, so that we can re-create the new one with previous value
93
- (_a = stripeStore.stripeAddressElement) === null || _a === void 0 ? void 0 : _a.destroy();
126
+ const stripeElement = this.getStripeAddressInstance().stripeAddressElement;
127
+ stripeElement === null || stripeElement === void 0 ? void 0 : stripeElement.destroy();
94
128
  }
95
129
  componentDidLoad() {
130
+ const stripeAddressEventData = this.getStripeAddressInstance().stripeAddressEventData;
131
+ this.isDirtyAddress =
132
+ !!stripeAddressEventData &&
133
+ stripeAddressEventData.value.address.line1.length > 0;
96
134
  // @Watch doesn't get trigger on initial load
97
135
  void this.watchInitStripe();
98
136
  }
99
137
  render() {
100
138
  // this component loads iframe from the stripe elements and puts here, so we don't need to do anything here
101
- return (h(Host, { key: '41014c1af1c8f8f5bb37caf358a6cec124e66f30', class: "zonos--address zonos--elements" }, h("zonos-text", { key: '5d8dcc4b44f7fe7b089b630ec6ca7b2177fef371', class: "zonos--title", type: "semiBoldLabel" }, this.titleText), h("div", { key: 'da0fe9760d7ca8dbc089481ac1dcb7c0a7c6553f', class: "zonos--address-component" })));
139
+ return (h(Host, { key: 'b2aa1ee3f16ae4ebcce83b599c97aa80f09dc9d3', class: "zonos--address zonos--elements" }, h("zonos-text", { key: 'e37392d0add0ab8541f78131abdf9082fd2455b4', class: "zonos--title", type: "semiBoldLabel" }, this.titleText), h("div", { key: 'd28d1908ee2f525455b0680e25cff3040093ad74', class: "zonos--address-component" })));
102
140
  }
103
141
  get el() { return this; }
104
142
  static get watchers() { return {
@@ -1,5 +1,5 @@
1
1
  import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
2
- import { b as zonosStoreFontFamily } from './zonosStore.js';
2
+ import { a as zonosStoreFontFamily } from './zonosStore.js';
3
3
  import { c as classes } from './classes.js';
4
4
  import { d as defineCustomElement$1 } from './zonos-text2.js';
5
5
 
@@ -12,34 +12,32 @@ const ZonosBadge = /*@__PURE__*/ proxyCustomElement(class ZonosBadge extends HTM
12
12
  this.__registerHost();
13
13
  this.__attachShadow();
14
14
  this.bold = false;
15
- this.color = 'gray';
15
+ this.badgeColor = 'gray';
16
16
  this.icon = undefined;
17
17
  this.iconRight = false;
18
18
  this.size = 'default';
19
19
  this.rounded = false;
20
- this.class = '';
21
20
  }
22
21
  render() {
23
- return (h(Host, { key: '2d111e91f403ef5c03f742f5dabe9491623be91d', class: classes(['zonos--elements zonos--badge', this.class]), style: {
22
+ return (h(Host, { key: '0f502b63322730f508fd7c92f231573b1dfbfd6b', class: classes(['zonos--elements zonos--badge']), style: {
24
23
  '--font-family': zonosStoreFontFamily(),
25
- } }, h("div", { key: 'e6debe091b732b857f180cee19bec4be435ea524', class: classes([
24
+ } }, h("div", { key: '4ee3f0b623067625ddd79336a1854f5ab796b3b1', class: classes([
26
25
  'zonos--badge-content',
27
- this.color,
26
+ this.badgeColor,
28
27
  this.rounded && 'rounded',
29
28
  this.iconRight && 'icon-right',
30
29
  this.size,
31
30
  this.bold && 'bold',
32
- ]) }, this.icon, h("zonos-text", { key: 'e92c97d77fa5ce279059953f7d7fbc5a0030aa5d' }, h("slot", { key: 'c93852c3225ba57dd26c26300254f348e349f9ad' })))));
31
+ ]) }, this.icon, h("zonos-text", { key: 'e5bdf974408416811f7666fc453ca47db58fa43f' }, h("slot", { key: 'd953b60fefe2c25aea529b9de41938cfd96a285b' })))));
33
32
  }
34
33
  static get style() { return ZonosBadgeStyle0; }
35
34
  }, [1, "zonos-badge", {
36
35
  "bold": [4],
37
- "color": [1],
36
+ "badgeColor": [1, "badge-color"],
38
37
  "icon": [16],
39
38
  "iconRight": [4, "icon-right"],
40
39
  "size": [1],
41
- "rounded": [4],
42
- "class": [1]
40
+ "rounded": [4]
43
41
  }]);
44
42
  function defineCustomElement() {
45
43
  if (typeof customElements === "undefined") {
@@ -1,5 +1,5 @@
1
1
  import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
2
- import { b as zonosStoreFontFamily } from './zonosStore.js';
2
+ import { a as zonosStoreFontFamily } from './zonosStore.js';
3
3
  import { c as classes } from './classes.js';
4
4
  import { d as defineCustomElement$1 } from './zonos-text2.js';
5
5
 
@@ -19,7 +19,6 @@ const ZonosBanner = /*@__PURE__*/ proxyCustomElement(class ZonosBanner extends H
19
19
  };
20
20
  this.bannerTitle = undefined;
21
21
  this.intent = undefined;
22
- this.class = '';
23
22
  this.hasContent = false;
24
23
  }
25
24
  render() {
@@ -31,13 +30,9 @@ const ZonosBanner = /*@__PURE__*/ proxyCustomElement(class ZonosBanner extends H
31
30
  h("slot", { onSlotchange: this.handleSlotChange }),
32
31
  ].filter(Boolean);
33
32
  const textColor = color === 'gray' ? 'gray-1200' : `${color}-800`;
34
- return (h("div", { class: classes(['zonos--container']) }, h("div", { class: "zonos--icon-wrapper" }, h("svg", { color: primaryColor, fill: "none", height: "20", viewBox: "0 0 24 24", width: "20", xmlns: "https://www.w3.org/2000/svg" }, h("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: secondaryColor, "fill-rule": "evenodd" }), h("path", { "clip-rule": "evenodd", d: "M12 6.99a1 1 0 0 1 1 1V8a1 1 0 1 1-2 0v-.01a1 1 0 0 1 1-1ZM12 11a1 1 0 0 1 1 1v4a1 1 0 1 1-2 0v-4a1 1 0 0 1 1-1Z", fill: "currentColor", "fill-rule": "evenodd" }))), h("div", { class: "zonos--header-wrapper" }, h("zonos-text", { color: textColor, type: "label", weight: 600 }, header)), content && (h("div", { class: "zonos--content-wrapper" }, h("zonos-text", { color: textColor }, content)))));
33
+ return (h("div", { class: classes(['zonos--container']) }, h("div", { class: "zonos--icon-wrapper" }, h("svg", { color: primaryColor, fill: "none", height: "20", viewBox: "0 0 24 24", width: "20", xmlns: "https://www.w3.org/2000/svg" }, h("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: secondaryColor, "fill-rule": "evenodd" }), h("path", { "clip-rule": "evenodd", d: "M12 6.99a1 1 0 0 1 1 1V8a1 1 0 1 1-2 0v-.01a1 1 0 0 1 1-1ZM12 11a1 1 0 0 1 1 1v4a1 1 0 1 1-2 0v-4a1 1 0 0 1 1-1Z", fill: "currentColor", "fill-rule": "evenodd" }))), h("div", { class: "zonos--header-wrapper" }, h("zonos-text", { textColor: textColor, type: "label", weight: 600 }, header)), content && (h("div", { class: "zonos--content-wrapper" }, h("zonos-text", { textColor: textColor }, content)))));
35
34
  };
36
- const baseClass = classes([
37
- 'zonos--elements zonos--banner',
38
- this.class,
39
- this.intent,
40
- ]);
35
+ const baseClass = classes(['zonos--elements zonos--banner', this.intent]);
41
36
  const font = zonosStoreFontFamily();
42
37
  switch (this.intent) {
43
38
  case 'error':
@@ -76,7 +71,6 @@ const ZonosBanner = /*@__PURE__*/ proxyCustomElement(class ZonosBanner extends H
76
71
  }, [1, "zonos-banner", {
77
72
  "bannerTitle": [1, "banner-title"],
78
73
  "intent": [1],
79
- "class": [1],
80
74
  "hasContent": [32]
81
75
  }]);
82
76
  function defineCustomElement() {
@@ -1,5 +1,5 @@
1
1
  import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
2
- import { z as zonosStore, b as zonosStoreFontFamily } from './zonosStore.js';
2
+ import { z as zonosStore, a as zonosStoreFontFamily } from './zonosStore.js';
3
3
  import { c as classes } from './classes.js';
4
4
  import { g as getBorderRadius } from './getBorderRadius.js';
5
5
  import { i as isColorVariable } from './isColorVariable.js';
@@ -20,7 +20,7 @@ const getButtonTheme = (overrideBackground) => {
20
20
  return buttonTheme;
21
21
  };
22
22
 
23
- const zonosButtonCss = ":host{font-family:var(--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--font-family, Inter), Inter}:host img{max-width:100%}:host dl,:host dd,:host h1,:host h2,:host h3,:host h4,:host h5,:host h6,:host hr,:host figure,:host p,:host pre{margin:0}:host{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}:host{display:-ms-inline-flexbox;display:inline-flex}:host .zonos--spinner-wrapper{position:absolute;top:0;left:0;right:0;bottom:0;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;background-color:var(--amino-surface-color);-ms-flex-pack:center;justify-content:center;border-radius:var(--amino-radius-10);gap:var(--amino-space-8)}:host button{width:100%;position:relative;font-size:14px;-webkit-box-sizing:border-box;box-sizing:border-box;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;background-color:var(--amino-surface-color);border:none;outline:1px solid var(--amino-surface-color);border-radius:var(--border-radius, var(--amino-radius-10));-webkit-transition:var(--amino-transition);transition:var(--amino-transition);font-weight:500;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;font-family:var(--font-family, Inter), Inter;letter-spacing:normal;cursor:pointer;white-space:nowrap;padding:var(--amino-space-8) var(--amino-space-24);color:var(--color, var(--amino-gray-1200));}:host button.sm.no-background,:host button.md.no-background,:host button.lg.no-background{background:none;outline:none}:host button.sm.no-padding-left,:host button.md.no-padding-left,:host button.lg.no-padding-left{padding-left:0}:host button.sm.no-padding-right,:host button.md.no-padding-right,:host button.lg.no-padding-right{padding-right:0}:host button[disabled]{cursor:not-allowed;background-color:var(--background-color, var(--amino-gray-200))}:host button[disabled] .zonos--spinner-wrapper{background-color:var(--background-color, var(--amino-gray-200))}:host button:active{-webkit-transform:scale(0.99);transform:scale(0.99)}:host button.sm{height:var(--amino-size-sm);line-height:var(--amino-size-sm);padding:var(--amino-space-4) var(--amino-space-8)}:host button.sm:not(.has-content).has-icon{padding:0 var(--amino-space-4)}:host button.md{height:var(--amino-size-md);line-height:var(--amino-size-md);padding:var(--amino-space-8) var(--amino-space-16)}:host button.md:not(.has-content).has-icon{padding:0 var(--amino-space-8)}:host button.lg{height:var(--amino-size-lg);line-height:var(--amino-size-lg);padding:var(--amino-space-12) var(--amino-space-24)}:host button.lg:not(.has-content).has-icon{padding:0 var(--amino-space-16)}:host button:not(.only-icon).has-icon{gap:var(--amino-space-8)}:host button.override-background{background-color:var(--background-color, var(--amino-gray-0));color:var(--color, var(--amino-gray-1200));outline:1px solid var(--background-color, var(--amino-gray-0))}:host button.override-background:disabled{opacity:0.8}:host button.override-background:not(:disabled):hover{opacity:0.9}:host button:not(.override-background){}:host button:not(.override-background).primary{background:var(--amino-blue-600);outline:1px solid var(--amino-blue-600);color:var(--amino-gray-0)}:host button:not(.override-background).primary:not([disabled]):hover{background-image:var(--amino-button-primary-hover)}:host button:not(.override-background).primary:not([disabled]):active{background:var(--amino-blue-700)}:host button:not(.override-background).primary:not([disabled]):focus{-webkit-box-shadow:var(--amino-focus-button);box-shadow:var(--amino-focus-button)}:host button:not(.override-background).primary[disabled]{background:var(--amino-blue-400)}:host button:not(.override-background).primary[disabled] .zonos--spinner-wrapper{background-color:var(--amino-blue-400)}:host button:not(.override-background).primary .zonos--spinner-wrapper{background-color:var(--amino-blue-600)}:host button:not(.override-background).success{background:var(--amino-green-600);outline:1px solid var(--amino-green-600);color:var(--amino-gray-0)}:host button:not(.override-background).success:not([disabled]):hover{background-image:var(--amino-button-success-hover)}:host button:not(.override-background).success:not([disabled]):active{background:var(--amino-green-700)}:host button:not(.override-background).success:not([disabled]):focus{-webkit-box-shadow:var(--amino-focus-button);box-shadow:var(--amino-focus-button)}:host button:not(.override-background).success[disabled]{background:var(--amino-green-400)}:host button:not(.override-background).success[disabled] .zonos--spinner-wrapper{background-color:var(--amino-green-400)}:host button:not(.override-background).danger{background:var(--amino-red-600);outline:1px solid var(--amino-red-600);color:var(--amino-gray-0)}:host button:not(.override-background).danger:not([disabled]):hover{background-image:var(--amino-button-danger-hover)}:host button:not(.override-background).danger:not([disabled]):active{background:var(--amino-red-700)}:host button:not(.override-background).danger:not([disabled]):focus{-webkit-box-shadow:var(--amino-focus-button);box-shadow:var(--amino-focus-button)}:host button:not(.override-background).danger[disabled]{background:var(--amino-red-400)}:host button:not(.override-background).danger[disabled] .zonos--spinner-wrapper{background-color:var(--amino-red-400)}:host button:not(.override-background).warning{background:var(--amino-orange-600);outline:1px solid var(--amino-orange-600);color:var(--amino-gray-0)}:host button:not(.override-background).warning:not([disabled]):hover{background-image:var(--amino-button-warning-hover)}:host button:not(.override-background).warning:not([disabled]):active{background:var(--amino-orange-700)}:host button:not(.override-background).warning:not([disabled]):focus{-webkit-box-shadow:var(--amino-focus-button);box-shadow:var(--amino-focus-button)}:host button:not(.override-background).warning[disabled]{background:var(--amino-orange-400)}:host button:not(.override-background).warning[disabled] .zonos--spinner-wrapper{background-color:var(--amino-orange-400)}:host button:not(.override-background).subtle{background:transparent;color:var(--color)}:host button:not(.override-background).subtle:not([disabled]):hover{background:var(--amino-gray-100)}:host button:not(.override-background).subtle:not([disabled]):active{background:var(--amino-gray-200)}:host button:not(.override-background).subtle:focus{-webkit-box-shadow:var(--amino-button-focus-ring);box-shadow:var(--amino-button-focus-ring)}:host button:not(.override-background).subtle[disabled] .content{opacity:0.6}:host button:not(.override-background).subtle[disabled] .zonos--spinner-wrapper{background-color:var(--amino-gray-0)}:host button:not(.override-background).outline{background:transparent;outline:1px solid var(--amino-gray-700)}:host button:not(.override-background).outline:not([disabled]):hover{background-color:var(--amino-gray-100)}:host button:not(.override-background).outline:not([disabled]):active{background:var(--amino-gray-200)}";
23
+ const zonosButtonCss = ":host{font-family:var(--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--font-family, Inter), Inter}:host img{max-width:100%}:host dl,:host dd,:host h1,:host h2,:host h3,:host h4,:host h5,:host h6,:host hr,:host figure,:host p,:host pre{margin:0}:host{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}:host{display:-ms-inline-flexbox;display:inline-flex}:host .zonos--spinner-wrapper{position:absolute;top:0;left:0;right:0;bottom:0;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;background-color:var(--amino-surface-color);-ms-flex-pack:center;justify-content:center;border-radius:var(--amino-radius-10);gap:var(--amino-space-8)}:host button{width:100%;position:relative;font-size:14px;-webkit-box-sizing:border-box;box-sizing:border-box;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;background-color:var(--amino-surface-color);border:none;outline:1px solid var(--amino-surface-color);border-radius:var(--border-radius, var(--amino-radius-10));-webkit-transition:var(--amino-transition);transition:var(--amino-transition);font-weight:500;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;font-family:var(--font-family, Inter), Inter;letter-spacing:normal;cursor:pointer;white-space:nowrap;padding:var(--amino-space-8) var(--amino-space-24);color:var(--color, var(--amino-gray-1200));}:host button.sm.no-background,:host button.md.no-background,:host button.lg.no-background{background:none;outline:none}:host button.sm.no-padding-left,:host button.md.no-padding-left,:host button.lg.no-padding-left{padding-left:0}:host button.sm.no-padding-right,:host button.md.no-padding-right,:host button.lg.no-padding-right{padding-right:0}:host button[disabled]{cursor:not-allowed;background-color:var(--background-color, var(--amino-gray-200))}:host button[disabled] .zonos--spinner-wrapper{background-color:var(--background-color, var(--amino-gray-200))}:host button:active{-webkit-transform:scale(0.99);transform:scale(0.99)}:host button.sm{height:var(--amino-size-sm);line-height:var(--amino-size-sm);padding:var(--amino-space-4) var(--amino-space-8)}:host button.sm:not(.has-content).has-icon{padding:0 var(--amino-space-4)}:host button.md{height:var(--amino-size-md);line-height:var(--amino-size-md);padding:var(--amino-space-8) var(--amino-space-16)}:host button.md:not(.has-content).has-icon{padding:0 var(--amino-space-8)}:host button.lg{height:var(--amino-size-lg);line-height:var(--amino-size-lg);padding:var(--amino-space-12) var(--amino-space-24)}:host button.lg:not(.has-content).has-icon{padding:0 var(--amino-space-16)}:host button:not(.only-icon).has-icon{gap:var(--amino-space-8)}@media (max-width: 400px){:host button:not(.only-icon).has-icon{font-size:var(--amino-font-size-s)}}:host button.override-background{background-color:var(--background-color, var(--amino-gray-0));color:var(--color, var(--amino-gray-1200));outline:1px solid var(--background-color, var(--amino-gray-0))}:host button.override-background:disabled{opacity:0.8}:host button.override-background:not(:disabled):hover{opacity:0.9}:host button:not(.override-background){}:host button:not(.override-background).primary{background:var(--amino-blue-600);outline:1px solid var(--amino-blue-600);color:var(--amino-gray-0)}:host button:not(.override-background).primary:not([disabled]):hover{background-image:var(--amino-button-primary-hover)}:host button:not(.override-background).primary:not([disabled]):active{background:var(--amino-blue-700)}:host button:not(.override-background).primary:not([disabled]):focus{-webkit-box-shadow:var(--amino-focus-button);box-shadow:var(--amino-focus-button)}:host button:not(.override-background).primary[disabled]{background:var(--amino-blue-400)}:host button:not(.override-background).primary[disabled] .zonos--spinner-wrapper{background-color:var(--amino-blue-400)}:host button:not(.override-background).primary .zonos--spinner-wrapper{background-color:var(--amino-blue-600)}:host button:not(.override-background).success{background:var(--amino-green-600);outline:1px solid var(--amino-green-600);color:var(--amino-gray-0)}:host button:not(.override-background).success:not([disabled]):hover{background-image:var(--amino-button-success-hover)}:host button:not(.override-background).success:not([disabled]):active{background:var(--amino-green-700)}:host button:not(.override-background).success:not([disabled]):focus{-webkit-box-shadow:var(--amino-focus-button);box-shadow:var(--amino-focus-button)}:host button:not(.override-background).success[disabled]{background:var(--amino-green-400)}:host button:not(.override-background).success[disabled] .zonos--spinner-wrapper{background-color:var(--amino-green-400)}:host button:not(.override-background).danger{background:var(--amino-red-600);outline:1px solid var(--amino-red-600);color:var(--amino-gray-0)}:host button:not(.override-background).danger:not([disabled]):hover{background-image:var(--amino-button-danger-hover)}:host button:not(.override-background).danger:not([disabled]):active{background:var(--amino-red-700)}:host button:not(.override-background).danger:not([disabled]):focus{-webkit-box-shadow:var(--amino-focus-button);box-shadow:var(--amino-focus-button)}:host button:not(.override-background).danger[disabled]{background:var(--amino-red-400)}:host button:not(.override-background).danger[disabled] .zonos--spinner-wrapper{background-color:var(--amino-red-400)}:host button:not(.override-background).warning{background:var(--amino-orange-600);outline:1px solid var(--amino-orange-600);color:var(--amino-gray-0)}:host button:not(.override-background).warning:not([disabled]):hover{background-image:var(--amino-button-warning-hover)}:host button:not(.override-background).warning:not([disabled]):active{background:var(--amino-orange-700)}:host button:not(.override-background).warning:not([disabled]):focus{-webkit-box-shadow:var(--amino-focus-button);box-shadow:var(--amino-focus-button)}:host button:not(.override-background).warning[disabled]{background:var(--amino-orange-400)}:host button:not(.override-background).warning[disabled] .zonos--spinner-wrapper{background-color:var(--amino-orange-400)}:host button:not(.override-background).subtle{background:transparent;color:var(--color);outline:none}:host button:not(.override-background).subtle:not([disabled]):hover{background:var(--amino-gray-100)}:host button:not(.override-background).subtle:not([disabled]):active{background:var(--amino-gray-200)}:host button:not(.override-background).subtle:focus{-webkit-box-shadow:var(--amino-button-focus-ring);box-shadow:var(--amino-button-focus-ring)}:host button:not(.override-background).subtle[disabled] .content{opacity:0.6}:host button:not(.override-background).subtle[disabled] .zonos--spinner-wrapper{background-color:var(--amino-gray-0)}:host button:not(.override-background).outline{background:transparent;outline:1px solid var(--amino-gray-700)}:host button:not(.override-background).outline:not([disabled]):hover{background-color:var(--amino-gray-100)}:host button:not(.override-background).outline:not([disabled]):active{background:var(--amino-gray-200)}:host .zonos--footer-country-flag{height:18px;width:18px;position:relative;overflow:hidden;border-radius:30px;-webkit-box-shadow:var(--amino-v3-shadow-medium);box-shadow:var(--amino-v3-shadow-medium);z-index:10;justify-self:center;border-radius:var(--amino-radius-4);width:24px}";
24
24
  const ZonosButtonStyle0 = zonosButtonCss;
25
25
 
26
26
  const ZonosButton = /*@__PURE__*/ proxyCustomElement(class ZonosButton extends HTMLElement {
@@ -34,8 +34,7 @@ const ZonosButton = /*@__PURE__*/ proxyCustomElement(class ZonosButton extends H
34
34
  this.handleSlotChange = () => {
35
35
  this.hasContent = true;
36
36
  };
37
- this.class = '';
38
- this.color = undefined;
37
+ this.buttonColor = undefined;
39
38
  this.backgroundColor = undefined;
40
39
  this.borderStyle = undefined;
41
40
  this.isDisabled = false;
@@ -73,21 +72,21 @@ const ZonosButton = /*@__PURE__*/ proxyCustomElement(class ZonosButton extends H
73
72
  * So need to re-assign the variant prop with the default value if the value is `undefined` here.
74
73
  */
75
74
  const variant = this.variant || 'standard';
76
- const color = this.color && isColorVariable(this.color)
77
- ? `var(--amino-${this.color})`
78
- : this.color;
75
+ const color = this.buttonColor && isColorVariable(this.buttonColor)
76
+ ? `var(--amino-${this.buttonColor})`
77
+ : this.buttonColor;
79
78
  // use override background if it exists, otherwise use color from setting
80
79
  const overrideBackground = this.backgroundColor || zonosStore.appearance.colorSecondary;
81
80
  // only set theme for button to change text color if variant is standard and override background is set
82
81
  const buttonTheme = variant === 'standard' ? getButtonTheme(overrideBackground) : undefined;
83
82
  const borderStyle = getBorderRadius(this.borderStyle);
84
83
  const spinnerColor = buttonTheme === 'LIGHT' ? 'white' : 'black';
85
- return (h(Host, { key: 'e1ad2eb31ad09c8671debc2e32d83af21085b912', class: classes(['zonos--elements', this.class]), "data-theme": this.theme || buttonTheme, disabled: disabled, style: {
84
+ return (h(Host, { key: '817142c1d229333aee0b38864788346d2749d3d1', class: classes(['zonos--elements']), "data-theme": this.theme || buttonTheme, disabled: disabled, style: {
86
85
  '--background-color': overrideBackground,
87
86
  '--border-radius': borderStyle,
88
87
  '--color': color,
89
88
  '--font-family': zonosStoreFontFamily(),
90
- } }, h("button", { key: '0a087bf98251899711a71d69a89473479fc78c4f', class: classes([
89
+ } }, h("button", { key: '04bff1f932154f54b4af51b2fac053d40efc354f', class: classes([
91
90
  this.hasIcon && 'has-icon',
92
91
  this.hasContent && 'has-content',
93
92
  this.noBackground && 'no-background',
@@ -100,15 +99,14 @@ const ZonosButton = /*@__PURE__*/ proxyCustomElement(class ZonosButton extends H
100
99
  overrideBackground &&
101
100
  variant === 'standard' &&
102
101
  'override-background',
103
- ]), disabled: disabled }, this.loading && (h("div", { class: "zonos--spinner-wrapper" }, h("zonos-spinner", { color: spinnerColor, size: 16 }))), !this.loading && !this.iconRight && this.icon, h("slot", { key: 'd80e58786f16bff52592a759679290a3a5ed0954', onSlotchange: this.handleSlotChange }), !this.loading && this.iconRight && this.icon)));
102
+ ]), disabled: disabled }, this.loading && (h("div", { class: "zonos--spinner-wrapper" }, h("zonos-spinner", { size: 16, spinnerColor: spinnerColor }))), !this.loading && !this.iconRight && this.icon, h("slot", { key: 'fd9bd0e9f89c3c9ab6dc9d0ac7a123542a1f5023', onSlotchange: this.handleSlotChange }), !this.loading && this.iconRight && this.icon)));
104
103
  }
105
104
  static get watchers() { return {
106
105
  "icon": ["iconChangeHandler"]
107
106
  }; }
108
107
  static get style() { return ZonosButtonStyle0; }
109
108
  }, [1, "zonos-button", {
110
- "class": [1],
111
- "color": [1],
109
+ "buttonColor": [1, "button-color"],
112
110
  "backgroundColor": [1, "background-color"],
113
111
  "borderStyle": [1, "border-style"],
114
112
  "isDisabled": [4, "is-disabled"],
@@ -1,5 +1,5 @@
1
1
  import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
2
- import { b as zonosStoreFontFamily } from './zonosStore.js';
2
+ import { a as zonosStoreFontFamily } from './zonosStore.js';
3
3
  import { c as classes } from './classes.js';
4
4
  import { d as defineCustomElement$1 } from './zonos-text2.js';
5
5
 
@@ -12,7 +12,6 @@ const ZonosCard = /*@__PURE__*/ proxyCustomElement(class ZonosCard extends HTMLE
12
12
  this.__registerHost();
13
13
  this.__attachShadow();
14
14
  this.actions = undefined;
15
- this.class = undefined;
16
15
  this.footerActions = undefined;
17
16
  this.footerContent = undefined;
18
17
  this.footerHeight = undefined;
@@ -20,9 +19,9 @@ const ZonosCard = /*@__PURE__*/ proxyCustomElement(class ZonosCard extends HTMLE
20
19
  this.spacing = '24px';
21
20
  }
22
21
  render() {
23
- return (h(Host, { key: 'f2f7929742862b9806ddc568155e7cddf954252e', style: {
22
+ return (h(Host, { key: '8581e04d45e7061bff02485ad9a9a22920b5fe84', style: {
24
23
  '--font-family': zonosStoreFontFamily(),
25
- } }, h("div", { key: 'ce3568d7ded3cfb9acb0f4ff3d4184a17b88f33b', class: classes(['styled-card', this.class]), style: { padding: this.spacing } }, this.label && (h("header", { class: "card-header", style: { padding: this.spacing } }, h("zonos-text", { type: "subheader" }, this.label), h("h-stack", { spacing: 8 }, this.actions))), h("slot", { key: '3cc9f896df1899da73eab80dfbb3aac3a0046956' }), (this.footerActions || this.footerContent) && (h("footer", { class: "card-footer", style: {
24
+ } }, h("div", { key: '5e2038438e0885602c2e15808a34d62e86c95035', class: classes(['styled-card']), style: { padding: this.spacing } }, this.label && (h("header", { class: "card-header", style: { padding: this.spacing } }, h("zonos-text", { type: "subheader" }, this.label), h("h-stack", { spacing: 8 }, this.actions))), h("slot", { key: 'b7cbddad1cc08256ae9192349fe5a44302b6d79e' }), (this.footerActions || this.footerContent) && (h("footer", { class: "card-footer", style: {
26
25
  height: this.footerHeight ? `${this.footerHeight}px` : 'auto',
27
26
  padding: this.spacing,
28
27
  } }, h("div", null, this.footerContent), h("h-stack", { spacing: 8 }, this.footerActions))))));
@@ -30,7 +29,6 @@ const ZonosCard = /*@__PURE__*/ proxyCustomElement(class ZonosCard extends HTMLE
30
29
  static get style() { return ZonosCardStyle0; }
31
30
  }, [1, "zonos-card", {
32
31
  "actions": [16],
33
- "class": [1],
34
32
  "footerActions": [16],
35
33
  "footerContent": [16],
36
34
  "footerHeight": [2, "footer-height"],
@@ -1,5 +1,5 @@
1
1
  import { proxyCustomElement, HTMLElement, getAssetPath, h, Host } from '@stencil/core/internal/client';
2
- import { c as cartStore } from './cart.js';
2
+ import { c as cartStore } from './stripe.js';
3
3
  import { f as formatCurrency } from './formatCurrency.js';
4
4
  import { d as defineCustomElement$1 } from './zonos-text2.js';
5
5
 
@@ -1,10 +1,10 @@
1
1
  import { proxyCustomElement, HTMLElement, h, Host, Fragment } from '@stencil/core/internal/client';
2
- import { c as cartStore } from './cart.js';
3
- import { t as translate } from './localization.js';
2
+ import { t as translate, c as cartStore } from './stripe.js';
4
3
  import { f as formatCurrency } from './formatCurrency.js';
5
- import { d as defineCustomElement$3 } from './zonos-badge2.js';
6
- import { d as defineCustomElement$2 } from './zonos-icon2.js';
7
- import { d as defineCustomElement$1 } from './zonos-text2.js';
4
+ import { d as defineCustomElement$4 } from './zonos-badge2.js';
5
+ import { d as defineCustomElement$3 } from './zonos-icon2.js';
6
+ import { d as defineCustomElement$2 } from './zonos-text2.js';
7
+ import { d as defineCustomElement$1 } from './zonos-tooltip2.js';
8
8
 
9
9
  const InfoIcon = `<svg viewBox="0 0 17 16" fill="none" xmlns="https://www.w3.org/2000/svg">
10
10
  <path fill-rule="evenodd" clip-rule="evenodd" d="M1.96704 8.00065C1.96704 4.31875 4.93024 1.33398 8.58554 1.33398C12.2408 1.33398 15.204 4.31875 15.204 8.00065C15.204 11.6826 12.2408 14.6673 8.58554 14.6673C4.93024 14.6673 1.96704 11.6825 1.96704 8.00065Z" fill="#C5C6CA"/>
@@ -38,7 +38,7 @@ const ZonosCartSubtotal = /*@__PURE__*/ proxyCustomElement(class ZonosCartSubtot
38
38
  amount: cartStore.shipping,
39
39
  currency: cartStore.currency,
40
40
  })
41
- : '-')), showDutyTaxesInfo && (h("tr", { class: "zonos--row zonos--cart-duties" }, h("td", { class: "zonos--column" }), h("td", { class: "zonos--column zonos--cart-subtotal-title" }, h("div", { class: "zonos--title-with-icon" }, h("zonos-text", { class: "zonos--title", type: "semiBoldLabel" }, translate('Duties, taxes, and fees')), h("zonos-icon", { content: InfoIcon, size: 16 })), !!cartStore.isSelectedShippingAboveDeminimis && (h("zonos-text", { color: "gray-800", type: "body" }, translate('Order is over the de minimis threshold for both duty and tax')))), h("td", { class: "zonos--column zonos--cart-subtotal-price" }, h("div", { class: "zonos--cart-duty-tax-price" }, cartStore.dutiesTaxFees
41
+ : '-')), showDutyTaxesInfo && (h("tr", { class: "zonos--row zonos--cart-duties" }, h("td", { class: "zonos--column" }), h("td", { class: "zonos--column zonos--cart-subtotal-title" }, h("div", { class: "zonos--title-with-icon" }, h("zonos-text", { class: "zonos--title", type: "semiBoldLabel" }, translate('Duties, taxes, and fees')), h("zonos-tooltip", { label: translate('Nothing due at the door') }, h("zonos-icon", { "aria-label": "Learn more about duties, taxes, and fees", content: InfoIcon, size: 16 }))), !!cartStore.isSelectedShippingAboveDeminimis && (h("zonos-text", { textColor: "gray-800", type: "body" }, translate('Order is over the de minimis threshold for both duty and tax')))), h("td", { class: "zonos--column zonos--cart-subtotal-price" }, h("div", { class: "zonos--cart-duty-tax-price" }, cartStore.dutiesTaxFees
42
42
  ? formatCurrency({
43
43
  amount: cartStore.dutiesTaxFees,
44
44
  currency: cartStore.currency,
@@ -59,7 +59,7 @@ function defineCustomElement() {
59
59
  if (typeof customElements === "undefined") {
60
60
  return;
61
61
  }
62
- const components = ["zonos-cart-subtotal", "zonos-badge", "zonos-icon", "zonos-text"];
62
+ const components = ["zonos-cart-subtotal", "zonos-badge", "zonos-icon", "zonos-text", "zonos-tooltip"];
63
63
  components.forEach(tagName => { switch (tagName) {
64
64
  case "zonos-cart-subtotal":
65
65
  if (!customElements.get(tagName)) {
@@ -68,15 +68,20 @@ function defineCustomElement() {
68
68
  break;
69
69
  case "zonos-badge":
70
70
  if (!customElements.get(tagName)) {
71
- defineCustomElement$3();
71
+ defineCustomElement$4();
72
72
  }
73
73
  break;
74
74
  case "zonos-icon":
75
75
  if (!customElements.get(tagName)) {
76
- defineCustomElement$2();
76
+ defineCustomElement$3();
77
77
  }
78
78
  break;
79
79
  case "zonos-text":
80
+ if (!customElements.get(tagName)) {
81
+ defineCustomElement$2();
82
+ }
83
+ break;
84
+ case "zonos-tooltip":
80
85
  if (!customElements.get(tagName)) {
81
86
  defineCustomElement$1();
82
87
  }
@@ -0,0 +1,11 @@
1
+ import type { Components, JSX } from "../types/components";
2
+
3
+ interface ZonosCheckbox extends Components.ZonosCheckbox, HTMLElement {}
4
+ export const ZonosCheckbox: {
5
+ prototype: ZonosCheckbox;
6
+ new (): ZonosCheckbox;
7
+ };
8
+ /**
9
+ * Used to define this component and all nested components recursively.
10
+ */
11
+ export const defineCustomElement: () => void;
@@ -0,0 +1,6 @@
1
+ import { Z as ZonosCheckbox$1, d as defineCustomElement$1 } from './zonos-checkbox2.js';
2
+
3
+ const ZonosCheckbox = ZonosCheckbox$1;
4
+ const defineCustomElement = defineCustomElement$1;
5
+
6
+ export { ZonosCheckbox, defineCustomElement };
@@ -0,0 +1,87 @@
1
+ import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
2
+ import { a as zonosStoreFontFamily } from './zonosStore.js';
3
+ import { c as classes } from './classes.js';
4
+ import { g as getBorderRadius } from './getBorderRadius.js';
5
+ import { i as isDarkColor } from './isDarkColor.js';
6
+ import { d as defineCustomElement$1 } from './zonos-text2.js';
7
+
8
+ const colorPrefixes = [
9
+ 'blue',
10
+ 'cyan',
11
+ 'green',
12
+ 'orange',
13
+ 'purple',
14
+ 'red',
15
+ 'gray',
16
+ 'glass',
17
+ ];
18
+
19
+ const zonosCheckboxCss = ":host{font-family:var(--font-family, Inter), Inter;display:block;white-space:normal}:host *{font-family:var(--font-family, Inter), Inter}:host img{max-width:100%}:host dl,:host dd,:host h1,:host h2,:host h3,:host h4,:host h5,:host h6,:host hr,:host figure,:host p,:host pre{margin:0}:host{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}:host{display:-ms-inline-flexbox;display:inline-flex}:host label{display:-ms-inline-flexbox;display:inline-flex;position:relative;gap:var(--amino-space-8);-ms-flex-align:center;align-items:center}:host label.disabled{cursor:not-allowed;opacity:0.6}:host input[type=checkbox]{opacity:0;position:absolute;left:0;width:0;height:0;top:0;z-index:-99999}:host svg{opacity:0}:host .checkmark-container{height:var(--size);width:var(--size);background-color:transparent;border:1.5px solid var(--amino-gray-400);position:relative;border-radius:var(--border-radius, var(--amino-radius-4))}:host .checkmark{opacity:0;position:absolute;top:-1.5px;left:-1.5px;right:-1.5px;bottom:-1.5px;-webkit-transition:0.3s all cubic-bezier(0.175, 0.885, 0.32, 1.275);transition:0.3s all cubic-bezier(0.175, 0.885, 0.32, 1.275);-webkit-transform:scale(0.4);transform:scale(0.4);background-color:var(--background-color);border-radius:var(--border-radius, var(--amino-radius-4))}:host input[type=checkbox]:checked~.checkmark-container .checkmark{opacity:1;-webkit-transform:scale(1);transform:scale(1)}";
20
+ const ZonosCheckboxStyle0 = zonosCheckboxCss;
21
+
22
+ const ZonosCheckbox = /*@__PURE__*/ proxyCustomElement(class ZonosCheckbox extends HTMLElement {
23
+ constructor() {
24
+ super();
25
+ this.__registerHost();
26
+ this.__attachShadow();
27
+ this.checkboxSelected = createEvent(this, "checkboxSelected", 7);
28
+ this.backgroundColor = 'blue';
29
+ this.label = undefined;
30
+ this.isChecked = false;
31
+ this.isDisabled = false;
32
+ this.size = 12;
33
+ this.fontSize = 'base';
34
+ this.borderStyle = undefined;
35
+ }
36
+ render() {
37
+ const isBackgroundVariable = colorPrefixes.includes(this.backgroundColor);
38
+ const backgroundColor = isBackgroundVariable
39
+ ? `var(--amino-${this.backgroundColor}-600)`
40
+ : this.backgroundColor;
41
+ const checkmarkColor = isBackgroundVariable
42
+ ? // use lighter color if the color is amino variable
43
+ `var(--amino-${this.backgroundColor}-200)`
44
+ : // if it's not an amino variable, use white if the background is dark, and dark if the background is light
45
+ !isDarkColor(backgroundColor)
46
+ ? 'var(--amino-gray-800)'
47
+ : 'var(--amino-gray-0)';
48
+ const borderStyle = getBorderRadius(this.borderStyle, '4px');
49
+ return (h(Host, { key: '86ab50028bec3f6a230b3a9492d06c1b2ce250fe', class: classes(['zonos--elements zonos--checkbox']), style: {
50
+ '--background-color': backgroundColor,
51
+ '--border-radius': borderStyle,
52
+ '--font-family': zonosStoreFontFamily(),
53
+ '--size': `${this.size}px`,
54
+ } }, h("label", { key: '88e87bb45739707a4e3da6d378ba491899dad76c', class: classes([this.isDisabled && 'disabled']) }, h("input", { key: 'c877ba4a2bd43aa67c394136ef4b3c71096e75aa', checked: this.isChecked, disabled: this.isDisabled, hidden: true, onChange: e => {
55
+ this.checkboxSelected.emit(e.target.checked);
56
+ }, type: "checkbox" }), h("span", { key: '0f40603a3cf90c38f37b05d7bfd8ed54623b07f4', class: "checkmark-container" }, h("svg", { key: '67945bb82cc05997bb40aeef14c5c0fd452a68af', class: "checkmark", color: checkmarkColor, fill: "none", viewBox: "0 0 24 24", xmlns: "http://www.w3.org/2000/svg" }, h("path", { key: 'ac2d1db7ba5c1578dbe59f4ca9755a409ab24546', "clip-rule": "evenodd", d: "M17.456 7.404a.75.75 0 0 1 .14 1.052l-6.5 8.5a.75.75 0 0 1-1.126.074l-4-4a.75.75 0 0 1 1.06-1.06l3.395 3.394 5.98-7.82a.75.75 0 0 1 1.05-.14Z", fill: "currentColor", "fill-rule": "evenodd" }))), this.label && (h("zonos-text", { size: this.fontSize }, this.label)))));
57
+ }
58
+ static get style() { return ZonosCheckboxStyle0; }
59
+ }, [1, "zonos-checkbox", {
60
+ "backgroundColor": [1, "background-color"],
61
+ "label": [1],
62
+ "isChecked": [4, "is-checked"],
63
+ "isDisabled": [4, "is-disabled"],
64
+ "size": [2],
65
+ "fontSize": [1, "font-size"],
66
+ "borderStyle": [1, "border-style"]
67
+ }]);
68
+ function defineCustomElement() {
69
+ if (typeof customElements === "undefined") {
70
+ return;
71
+ }
72
+ const components = ["zonos-checkbox", "zonos-text"];
73
+ components.forEach(tagName => { switch (tagName) {
74
+ case "zonos-checkbox":
75
+ if (!customElements.get(tagName)) {
76
+ customElements.define(tagName, ZonosCheckbox);
77
+ }
78
+ break;
79
+ case "zonos-text":
80
+ if (!customElements.get(tagName)) {
81
+ defineCustomElement$1();
82
+ }
83
+ break;
84
+ } });
85
+ }
86
+
87
+ export { ZonosCheckbox as Z, defineCustomElement as d };
@@ -1,6 +1,5 @@
1
1
  import { proxyCustomElement, HTMLElement, createEvent, h, Host, Fragment } from '@stencil/core/internal/client';
2
- import { s as stripeStore, p as stripeStoreRetrievePayment, o as stripeStoreReset, c as cartStore } from './cart.js';
3
- import { h as handleFetch, t as translate } from './localization.js';
2
+ import { o as handleFetch, s as stripeStore, p as stripeStoreRetrievePayment, t as translate, m as stripeStoreReset, c as cartStore } from './stripe.js';
4
3
  import { z as zonosStore } from './zonosStore.js';
5
4
  import { g as getBorderRadius } from './getBorderRadius.js';
6
5
  import { s as submitGtag } from './submitGtag.js';
@@ -47,6 +46,11 @@ const ZonosCheckoutFinish = /*@__PURE__*/ proxyCustomElement(class ZonosCheckout
47
46
  case 'CLOSE_MODAL':
48
47
  this.closeClickHandler();
49
48
  break;
49
+ case 'ZONOS_SUCCESS_PAGE':
50
+ default:
51
+ // Do nothing, display Zonos success page
52
+ this.isLoading = false;
53
+ break;
50
54
  }
51
55
  };
52
56
  // TODO: This method of pulling orders is temporary. Once we have a working event registry system, we will rely on that to tell us when the order is ready to trigger onOrderSuccess
@@ -55,7 +59,6 @@ const ZonosCheckoutFinish = /*@__PURE__*/ proxyCustomElement(class ZonosCheckout
55
59
  if (order) {
56
60
  this.order = order;
57
61
  this.handleSuccessBehavior(order.id);
58
- this.isLoading = false;
59
62
  }
60
63
  else if (!order && attempts < 5) {
61
64
  // Wait for 1 second before the next attempt
@@ -107,12 +110,17 @@ const ZonosCheckoutFinish = /*@__PURE__*/ proxyCustomElement(class ZonosCheckout
107
110
  }
108
111
  // Attempt to pull the order details from the graph every second on 5 attempts
109
112
  if (this.notificationType === 'success') {
110
- this.isLoading = true;
111
113
  void this.getPullOrder();
112
114
  }
115
+ else {
116
+ this.isLoading = false;
117
+ }
118
+ }
119
+ else {
120
+ this.isLoading = false;
113
121
  }
114
122
  stripeStoreReset();
115
- this.isLoading = false;
123
+ cartStore.checkoutSessionId = null;
116
124
  };
117
125
  this.closeClickHandler = () => {
118
126
  this.closeClick.emit();
@@ -145,9 +153,9 @@ const ZonosCheckoutFinish = /*@__PURE__*/ proxyCustomElement(class ZonosCheckout
145
153
  // const totalItems = this.order?.items?.reduce((acc, item) => {
146
154
  // return acc + item.quantity;
147
155
  // }, 0);
148
- return (h(Host, { key: 'bdf824c48f7f01bcafd88b17ad758d05ab589ffd', class: "zonos--checkout-finish zonos--elements", style: {
156
+ return (h(Host, { key: '08886ec74e789091534c8bd6561a8349a5a6966c', class: "zonos--checkout-finish zonos--elements", style: {
149
157
  '--border-radius': getBorderRadius(this.borderRadius),
150
- } }, this.isLoading && (h("div", { class: "loading-wrapper" }, h("zonos-spinner", null))), !this.isLoading && (h(Fragment, null, h("div", { class: "zonos--group" }, this.notificationType === 'success' ? (h("zonos-icon", { color: 'blue-800', content: SuccessIcon, size: 50 })) : (h("zonos-icon", { color: 'red-800', content: RemoveIcon, size: 50 })), h("zonos-text", { class: "zonos--title", type: "semiBoldSubheader" }, this.notificationTitle), h("zonos-text", null, this.notificationMessages.map(message => (h(Fragment, null, message, h("br", null))))), h("zonos-button", { onClick: () => this.closeClickHandler(), size: "md", variant: "primary" }, translate('Keep shopping')))))));
158
+ } }, this.isLoading && (h("div", { class: "loading-wrapper" }, h("zonos-spinner", null))), !this.isLoading && (h(Fragment, null, h("div", { 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", { class: "zonos--title", type: "semiBoldSubheader" }, this.notificationTitle), h("zonos-text", null, this.notificationMessages.map(message => (h(Fragment, null, message, h("br", null))))), h("zonos-button", { onClick: () => this.closeClickHandler(), size: "md", variant: "primary" }, translate('Keep shopping')))))));
151
159
  }
152
160
  static get assetsDirs() { return ["assets"]; }
153
161
  static get style() { return ZonosCheckoutFinishStyle0; }