@zonos/elements 1.1.2 → 1.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (780) hide show
  1. package/dist/cjs/{cart-a969ee0b.js → cart-7b70853c.js} +7 -15
  2. package/dist/cjs/classes-b7918f56.js +0 -2
  3. package/dist/cjs/{getBorderRadius-ae52cae1.js → getBorderRadius-fdd605c6.js} +1 -3
  4. package/dist/cjs/getHasMoreSpaceOnRight-2855491b.js +0 -2
  5. package/dist/cjs/index-9542d2e7.js +0 -2
  6. package/dist/cjs/index.cjs.js +20 -1
  7. package/dist/cjs/isColorVariable-c1ed7303.js +0 -2
  8. package/dist/cjs/{isDarkColor-e1a7bf45.js → isDarkColor-f3446afd.js} +1 -3
  9. package/dist/cjs/loader.cjs.js +1 -3
  10. package/dist/cjs/{localization-d510574c.js → localization-387a8a65.js} +11 -7
  11. package/dist/cjs/{submitGtag-4de4430f.js → submitGtag-bf6e7c5e.js} +2 -4
  12. package/dist/cjs/zonos-address_2.cjs.entry.js +5 -7
  13. package/dist/cjs/zonos-badge.cjs.entry.js +0 -2
  14. package/dist/cjs/zonos-banner.cjs.entry.js +0 -2
  15. package/dist/cjs/zonos-button_2.cjs.entry.js +3 -5
  16. package/dist/cjs/zonos-card_2.cjs.entry.js +0 -2
  17. package/dist/cjs/zonos-cart-items_10.cjs.entry.js +24 -18
  18. package/dist/cjs/zonos-checkout.cjs.entry.js +95 -48
  19. package/dist/cjs/zonos-component.cjs.entry.js +0 -2
  20. package/dist/cjs/zonos-controller.cjs.entry.js +17 -12
  21. package/dist/cjs/zonos-country-flag_4.cjs.entry.js +3 -5
  22. package/dist/cjs/zonos-elements.cjs.js +1 -3
  23. package/dist/cjs/zonos-hello-dialog.cjs.entry.js +12 -5
  24. package/dist/cjs/zonos-hello.cjs.entry.js +25 -9
  25. package/dist/cjs/zonos-icon.cjs.entry.js +0 -2
  26. package/dist/cjs/zonos-notification.cjs.entry.js +0 -2
  27. package/dist/cjs/zonos-payment.cjs.entry.js +5 -7
  28. package/dist/cjs/zonos-shipping-rich-radio.cjs.entry.js +3 -5
  29. package/dist/cjs/zonos-text.cjs.entry.js +0 -2
  30. package/dist/cjs/{zonosStore-d9cdaec6.js → zonosStore-a430ec5b.js} +3 -2
  31. package/dist/collection/components/checkout/zonos-checkout/zonos-cart-items/zonos-cart-items.js +0 -1
  32. package/dist/collection/components/checkout/zonos-checkout/zonos-cart-subtotal/zonos-cart-subtotal.css +6 -0
  33. package/dist/collection/components/checkout/zonos-checkout/zonos-cart-subtotal/zonos-cart-subtotal.js +3 -3
  34. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-finish/zonos-checkout-finish.js +7 -1
  35. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-payment/zonos-checkout-payment.css +7 -3
  36. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-payment/zonos-checkout-payment.js +2 -3
  37. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout.js +93 -62
  38. package/dist/collection/components/checkout/zonos-checkout/zonos-customer-info/zonos-customer-info.css +7 -3
  39. package/dist/collection/components/checkout/zonos-checkout/zonos-customer-info/zonos-customer-info.js +2 -3
  40. package/dist/collection/components/checkout/zonos-checkout/zonos-review/zonos-review.js +0 -1
  41. package/dist/collection/components/checkout/zonos-checkout/zonos-shipping/zonos-shipping.css +7 -3
  42. package/dist/collection/components/checkout/zonos-checkout/zonos-shipping/zonos-shipping.js +0 -1
  43. package/dist/collection/components/common/countries.js +0 -1
  44. package/dist/collection/components/common/zonos-badge/zonos-badge.js +0 -1
  45. package/dist/collection/components/common/zonos-banner/zonos-banner.js +0 -1
  46. package/dist/collection/components/common/zonos-button/zonos-button.js +0 -1
  47. package/dist/collection/components/common/zonos-card/zonos-card.js +0 -1
  48. package/dist/collection/components/common/zonos-collapse/zonos-collapse.js +0 -1
  49. package/dist/collection/components/common/zonos-country-flag/zonos-country-flag.js +0 -1
  50. package/dist/collection/components/common/zonos-country-select/zonos-country-select.js +0 -1
  51. package/dist/collection/components/common/zonos-custom-message/zonos-custom-message.js +0 -1
  52. package/dist/collection/components/common/zonos-dialog/zonos-dialog.js +0 -1
  53. package/dist/collection/components/common/zonos-icon/zonos-icon.js +0 -1
  54. package/dist/collection/components/common/zonos-logo/zonos-logo.js +0 -1
  55. package/dist/collection/components/common/zonos-notification/zonos-notification.js +0 -1
  56. package/dist/collection/components/common/zonos-shipping-rich-radio/zonos-shipping-rich-radio.css +5 -2
  57. package/dist/collection/components/common/zonos-shipping-rich-radio/zonos-shipping-rich-radio.js +0 -1
  58. package/dist/collection/components/common/zonos-spinner/zonos-spinner.js +0 -1
  59. package/dist/collection/components/common/zonos-text/zonos-text.js +0 -1
  60. package/dist/collection/components/common/zonos-v-stack/zonos-v-stack.js +0 -1
  61. package/dist/collection/components/component-template/zonos-component/zonos-component.js +0 -1
  62. package/dist/collection/components/hello/zonos-hello/zonos-hello.js +23 -6
  63. package/dist/collection/components/hello/zonos-hello-dialog/zonos-hello-dialog-footer/zonos-hello-dialog-footer.js +0 -1
  64. package/dist/collection/components/hello/zonos-hello-dialog/zonos-hello-dialog.css +8 -0
  65. package/dist/collection/components/hello/zonos-hello-dialog/zonos-hello-dialog.js +3 -1
  66. package/dist/collection/components/main/zonos-controller.js +10 -2
  67. package/dist/collection/components/store/checkout/cart.js +0 -1
  68. package/dist/collection/components/store/checkout/stripe.js +0 -1
  69. package/dist/collection/components/store/hello/localization.js +4 -1
  70. package/dist/collection/components/store/translationStore/strings.arabic.js +0 -1
  71. package/dist/collection/components/store/translationStore/strings.base.js +0 -1
  72. package/dist/collection/components/store/translationStore/strings.chinese.js +0 -1
  73. package/dist/collection/components/store/translationStore/strings.danish.js +0 -1
  74. package/dist/collection/components/store/translationStore/strings.dutch.js +0 -1
  75. package/dist/collection/components/store/translationStore/strings.french.js +0 -1
  76. package/dist/collection/components/store/translationStore/strings.german.js +0 -1
  77. package/dist/collection/components/store/translationStore/strings.hebrew.js +0 -1
  78. package/dist/collection/components/store/translationStore/strings.indonesian.js +0 -1
  79. package/dist/collection/components/store/translationStore/strings.italian.js +0 -1
  80. package/dist/collection/components/store/translationStore/strings.japanese.js +0 -1
  81. package/dist/collection/components/store/translationStore/strings.korean.js +0 -1
  82. package/dist/collection/components/store/translationStore/strings.norwegian.js +0 -1
  83. package/dist/collection/components/store/translationStore/strings.polish.js +0 -1
  84. package/dist/collection/components/store/translationStore/strings.portuguese.js +0 -1
  85. package/dist/collection/components/store/translationStore/strings.russian.js +0 -1
  86. package/dist/collection/components/store/translationStore/strings.spanish.js +0 -1
  87. package/dist/collection/components/store/translationStore/strings.swedish.js +0 -1
  88. package/dist/collection/components/store/translationStore/strings.turkish.js +0 -1
  89. package/dist/collection/components/store/translationStore/strings.vietnamese.js +0 -1
  90. package/dist/collection/components/store/translationStore.js +0 -1
  91. package/dist/collection/components/store/zonosStore.js +3 -1
  92. package/dist/collection/components/stripe/zonos-address/zonos-address.js +0 -1
  93. package/dist/collection/components/stripe/zonos-link-authentication/zonos-link-authentication.js +0 -1
  94. package/dist/collection/components/stripe/zonos-payment/zonos-payment.js +0 -1
  95. package/dist/collection/components/utils/addDays.js +0 -1
  96. package/dist/collection/components/utils/api/calculateLandedCost.js +0 -1
  97. package/dist/collection/components/utils/api/checkItemRestrictions.js +0 -1
  98. package/dist/collection/components/utils/api/getCountries.js +0 -1
  99. package/dist/collection/components/utils/api/getCountryLandedCost.js +0 -1
  100. package/dist/collection/components/utils/api/getExchangeRate.js +2 -3
  101. package/dist/collection/components/utils/api/getLocaleMessages.js +0 -1
  102. package/dist/collection/components/utils/api/getLocalization.js +3 -2
  103. package/dist/collection/components/utils/api/getShippingZones.js +0 -1
  104. package/dist/collection/components/utils/api/getZonosSetting.js +0 -1
  105. package/dist/collection/components/utils/api/prepCalculateLandedCost.js +1 -10
  106. package/dist/collection/components/utils/changeDeepProperty.js +0 -1
  107. package/dist/collection/components/utils/changeDeepPropertyAtIndex.js +0 -1
  108. package/dist/collection/components/utils/checkout/initCheckout.js +2 -5
  109. package/dist/collection/components/utils/checkout/isCheckoutMobile.js +0 -1
  110. package/dist/collection/components/utils/classes.js +0 -1
  111. package/dist/collection/components/utils/darkenColor.js +0 -1
  112. package/dist/collection/components/utils/formatCurrency.js +0 -1
  113. package/dist/collection/components/utils/formatDate.js +0 -1
  114. package/dist/collection/components/utils/getBorderRadius.js +0 -1
  115. package/dist/collection/components/utils/getButtonTheme.js +0 -1
  116. package/dist/collection/components/utils/getDaysDifference.js +0 -1
  117. package/dist/collection/components/utils/handleFetch.js +1 -2
  118. package/dist/collection/components/utils/hello/currencyConversion/currencyConvert.js +0 -1
  119. package/dist/collection/components/utils/hello/currencyConversion/currencyConvertAndFormat.js +0 -1
  120. package/dist/collection/components/utils/hello/currencyConversion/currencyDisplay.js +0 -1
  121. package/dist/collection/components/utils/hello/currencyConversion/currencyFormat.js +0 -1
  122. package/dist/collection/components/utils/hello/currencyConversion/defaultCurrencyConverter.js +0 -1
  123. package/dist/collection/components/utils/hello/currencyConversion/getCurrencyCode.js +0 -1
  124. package/dist/collection/components/utils/hello/currencyConversion/getCurrencyElements.js +0 -1
  125. package/dist/collection/components/utils/hello/currencyConversion/getInitialElementAmount.js +0 -1
  126. package/dist/collection/components/utils/hello/currencyConversion/getLanguageCode.js +0 -1
  127. package/dist/collection/components/utils/hello/detectItemRestrictions.js +0 -1
  128. package/dist/collection/components/utils/hello/getCurrentHelloLocalePage.js +0 -1
  129. package/dist/collection/components/utils/hello/getHasMoreSpaceAbove.js +9 -0
  130. package/dist/collection/components/utils/hello/getHasMoreSpaceOnRight.js +0 -1
  131. package/dist/collection/components/utils/hello/getProductsOnPage.js +0 -1
  132. package/dist/collection/components/utils/hello/initHello.js +0 -1
  133. package/dist/collection/components/utils/hello/setZonosCountryUrlParam.js +0 -1
  134. package/dist/collection/components/utils/isColorVariable.js +0 -1
  135. package/dist/collection/components/utils/isDarkColor.js +0 -1
  136. package/dist/collection/components/utils/isValidSelector.js +0 -1
  137. package/dist/collection/components/utils/jsonParse.js +0 -1
  138. package/dist/collection/components/utils/lightenColor.js +0 -1
  139. package/dist/collection/components/utils/logging/log.js +0 -1
  140. package/dist/collection/components/utils/logging/logError.js +0 -1
  141. package/dist/collection/components/utils/mergeConfig.js +0 -1
  142. package/dist/collection/components/utils/submitGtag.js +0 -1
  143. package/dist/collection/environment.js +60 -13
  144. package/dist/collection/index.js +0 -1
  145. package/dist/collection/scripts/loadStripe.js +0 -1
  146. package/dist/collection/scripts/stripe.js +0 -1
  147. package/dist/collection/scripts/zonos.js +4 -2
  148. package/dist/collection/styles/stripe/addressRuleStyle.js +0 -1
  149. package/dist/collection/styles/stripe/defaultVariable.js +0 -1
  150. package/dist/collection/types/ICountryJson.js +0 -1
  151. package/dist/collection/types/JsonError.js +0 -1
  152. package/dist/collection/types/NoInfer.js +0 -1
  153. package/dist/collection/types/Translation.js +0 -1
  154. package/dist/collection/types/checkout/CheckoutConfig.js +0 -1
  155. package/dist/collection/types/checkout/api/CalculateLandedCostRequest.js +0 -1
  156. package/dist/collection/types/generated/graphql.customer.types.js +61 -1
  157. package/dist/collection/types/generated/graphql.frontend.types.js +0 -1
  158. package/dist/collection/types/hello/HelloConfig.js +0 -1
  159. package/dist/collection/types/hello/Product.js +0 -1
  160. package/dist/collection/types/hello/RestrictedItem.js +0 -1
  161. package/dist/collection/types/index.js +1 -1
  162. package/dist/collection/types/online-store/OnlineStoreConfig.js +0 -1
  163. package/dist/collection/types/stripe/Apperance.js +0 -1
  164. package/dist/collection/types/styles/Color.js +0 -1
  165. package/dist/collection/types/styles/GridSpacing.js +0 -1
  166. package/dist/collection/types/styles/Text.js +0 -1
  167. package/dist/collection/types/utils/deep/IDeepKeyof.js +0 -1
  168. package/dist/collection/types/utils/deep/IDeepKeyofAtIndex.js +0 -1
  169. package/dist/collection/utils/format.js +0 -1
  170. package/dist/collection/utils/generateVercelDeployUrl.js +0 -1
  171. package/dist/{esm/cart-d00e1acb.js → components/cart.js} +6 -16
  172. package/dist/components/classes.js +0 -2
  173. package/dist/components/formatCurrency.js +0 -2
  174. package/dist/components/getBorderRadius.js +0 -2
  175. package/dist/components/index.js +1 -2
  176. package/dist/components/isColorVariable.js +0 -2
  177. package/dist/components/isDarkColor.js +0 -2
  178. package/dist/components/localization.js +11 -7
  179. package/dist/components/submitGtag.js +1 -3
  180. package/dist/components/zonos-address.js +0 -2
  181. package/dist/components/zonos-address2.js +2 -4
  182. package/dist/components/zonos-badge.js +0 -2
  183. package/dist/components/zonos-badge2.js +0 -2
  184. package/dist/components/zonos-banner.js +0 -2
  185. package/dist/components/zonos-banner2.js +0 -2
  186. package/dist/components/zonos-button.js +0 -2
  187. package/dist/components/zonos-button2.js +0 -2
  188. package/dist/components/zonos-card.js +0 -2
  189. package/dist/components/zonos-card2.js +0 -2
  190. package/dist/components/zonos-cart-items.js +0 -2
  191. package/dist/components/zonos-cart-items2.js +1 -3
  192. package/dist/components/zonos-cart-subtotal.js +0 -2
  193. package/dist/components/zonos-cart-subtotal2.js +5 -6
  194. package/dist/components/zonos-checkout-finish.js +0 -2
  195. package/dist/components/zonos-checkout-finish2.js +8 -3
  196. package/dist/components/zonos-checkout-payment.js +0 -2
  197. package/dist/components/zonos-checkout-payment2.js +4 -6
  198. package/dist/components/zonos-checkout.js +91 -45
  199. package/dist/components/zonos-collapse.js +0 -2
  200. package/dist/components/zonos-collapse2.js +0 -2
  201. package/dist/components/zonos-component.js +0 -2
  202. package/dist/components/zonos-controller.js +14 -9
  203. package/dist/components/zonos-country-flag.js +0 -2
  204. package/dist/components/zonos-country-flag2.js +1 -3
  205. package/dist/components/zonos-country-select.js +0 -2
  206. package/dist/components/zonos-country-select2.js +1 -3
  207. package/dist/components/zonos-custom-message.js +0 -2
  208. package/dist/components/zonos-custom-message2.js +0 -2
  209. package/dist/components/zonos-customer-info.js +0 -2
  210. package/dist/components/zonos-customer-info2.js +4 -6
  211. package/dist/components/zonos-dialog.js +0 -2
  212. package/dist/components/zonos-dialog2.js +0 -2
  213. package/dist/components/zonos-hello-dialog-footer.js +0 -2
  214. package/dist/components/zonos-hello-dialog-footer2.js +1 -3
  215. package/dist/components/zonos-hello-dialog.js +0 -2
  216. package/dist/components/zonos-hello-dialog2.js +11 -4
  217. package/dist/components/zonos-hello.js +24 -8
  218. package/dist/components/zonos-icon.js +0 -2
  219. package/dist/components/zonos-icon2.js +0 -2
  220. package/dist/components/zonos-link-authentication.js +0 -2
  221. package/dist/components/zonos-link-authentication2.js +1 -3
  222. package/dist/components/zonos-logo.js +0 -2
  223. package/dist/components/zonos-logo2.js +0 -2
  224. package/dist/components/zonos-notification.js +0 -2
  225. package/dist/components/zonos-notification2.js +0 -2
  226. package/dist/components/zonos-payment.js +0 -2
  227. package/dist/components/zonos-payment2.js +1 -3
  228. package/dist/components/zonos-review.js +0 -2
  229. package/dist/components/zonos-review2.js +1 -3
  230. package/dist/components/zonos-shipping-rich-radio.js +0 -2
  231. package/dist/components/zonos-shipping-rich-radio2.js +1 -3
  232. package/dist/components/zonos-shipping.js +0 -2
  233. package/dist/components/zonos-shipping2.js +2 -4
  234. package/dist/components/zonos-spinner.js +0 -2
  235. package/dist/components/zonos-spinner2.js +0 -2
  236. package/dist/components/zonos-text.js +0 -2
  237. package/dist/components/zonos-text2.js +0 -2
  238. package/dist/components/zonos-v-stack.js +0 -2
  239. package/dist/components/zonos-v-stack2.js +0 -2
  240. package/dist/components/zonosStore.js +3 -2
  241. package/dist/{zonos-elements/cart-d00e1acb.js → esm/cart-07091d2a.js} +6 -16
  242. package/dist/esm/classes-0d95c529.js +0 -2
  243. package/dist/esm/{getBorderRadius-e8ad5967.js → getBorderRadius-45764ad7.js} +1 -3
  244. package/dist/esm/getHasMoreSpaceOnRight-feba1ae2.js +0 -2
  245. package/dist/esm/index-d1aa9293.js +0 -2
  246. package/dist/esm/index.js +6 -3
  247. package/dist/esm/isColorVariable-4cda28c9.js +0 -2
  248. package/dist/{zonos-elements/isDarkColor-3bb345f4.js → esm/isDarkColor-6fbb9b14.js} +1 -3
  249. package/dist/esm/loader.js +1 -3
  250. package/dist/{zonos-elements/localization-1d92a557.js → esm/localization-b3c2a9a9.js} +11 -7
  251. package/dist/esm/{submitGtag-85914088.js → submitGtag-c0b655ad.js} +2 -4
  252. package/dist/esm/zonos-address_2.entry.js +5 -7
  253. package/dist/esm/zonos-badge.entry.js +0 -2
  254. package/dist/esm/zonos-banner.entry.js +0 -2
  255. package/dist/esm/zonos-button_2.entry.js +3 -5
  256. package/dist/esm/zonos-card_2.entry.js +0 -2
  257. package/dist/esm/zonos-cart-items_10.entry.js +24 -18
  258. package/dist/esm/zonos-checkout.entry.js +95 -48
  259. package/dist/esm/zonos-component.entry.js +0 -2
  260. package/dist/esm/zonos-controller.entry.js +17 -12
  261. package/dist/esm/zonos-country-flag_4.entry.js +3 -5
  262. package/dist/esm/zonos-elements.js +1 -3
  263. package/dist/esm/zonos-hello-dialog.entry.js +12 -5
  264. package/dist/esm/zonos-hello.entry.js +25 -9
  265. package/dist/esm/zonos-icon.entry.js +0 -2
  266. package/dist/esm/zonos-notification.entry.js +0 -2
  267. package/dist/esm/zonos-payment.entry.js +5 -7
  268. package/dist/esm/zonos-shipping-rich-radio.entry.js +3 -5
  269. package/dist/esm/zonos-text.entry.js +0 -2
  270. package/dist/{zonos-elements/zonosStore-1c9c7d76.js → esm/zonosStore-05a62104.js} +3 -2
  271. package/dist/esm-es5/cart-07091d2a.js +1 -0
  272. package/dist/esm-es5/classes-0d95c529.js +1 -2
  273. package/dist/esm-es5/getBorderRadius-45764ad7.js +1 -0
  274. package/dist/esm-es5/getHasMoreSpaceOnRight-feba1ae2.js +1 -2
  275. package/dist/esm-es5/index-d1aa9293.js +1 -2
  276. package/dist/esm-es5/index.js +1 -2
  277. package/dist/esm-es5/isColorVariable-4cda28c9.js +1 -2
  278. package/dist/esm-es5/{isDarkColor-3bb345f4.js → isDarkColor-6fbb9b14.js} +1 -2
  279. package/dist/esm-es5/loader.js +1 -2
  280. package/dist/esm-es5/{localization-1d92a557.js → localization-b3c2a9a9.js} +1 -2
  281. package/dist/esm-es5/{submitGtag-85914088.js → submitGtag-c0b655ad.js} +1 -2
  282. package/dist/esm-es5/zonos-address_2.entry.js +1 -2
  283. package/dist/esm-es5/zonos-badge.entry.js +1 -2
  284. package/dist/esm-es5/zonos-banner.entry.js +1 -2
  285. package/dist/esm-es5/zonos-button_2.entry.js +1 -2
  286. package/dist/esm-es5/zonos-card_2.entry.js +1 -2
  287. package/dist/esm-es5/zonos-cart-items_10.entry.js +1 -2
  288. package/dist/esm-es5/zonos-checkout.entry.js +1 -2
  289. package/dist/esm-es5/zonos-component.entry.js +1 -2
  290. package/dist/esm-es5/zonos-controller.entry.js +1 -2
  291. package/dist/esm-es5/zonos-country-flag_4.entry.js +1 -2
  292. package/dist/esm-es5/zonos-elements.js +1 -2
  293. package/dist/esm-es5/zonos-hello-dialog.entry.js +1 -2
  294. package/dist/esm-es5/zonos-hello.entry.js +1 -2
  295. package/dist/esm-es5/zonos-icon.entry.js +1 -2
  296. package/dist/esm-es5/zonos-notification.entry.js +1 -2
  297. package/dist/esm-es5/zonos-payment.entry.js +1 -2
  298. package/dist/esm-es5/zonos-shipping-rich-radio.entry.js +1 -2
  299. package/dist/esm-es5/zonos-text.entry.js +1 -2
  300. package/dist/esm-es5/{zonosStore-1c9c7d76.js → zonosStore-05a62104.js} +1 -2
  301. package/dist/scripts/loadZonos.js +6 -3
  302. package/dist/scripts/zonos.js +6 -3
  303. package/dist/types/components/checkout/zonos-checkout/zonos-checkout.d.ts +1 -4
  304. package/dist/types/components/hello/zonos-hello/zonos-hello.d.ts +1 -0
  305. package/dist/types/components/store/checkout/cart.d.ts +14 -1
  306. package/dist/types/components/utils/api/getExchangeRate.d.ts +2 -1
  307. package/dist/types/components/utils/hello/getHasMoreSpaceAbove.d.ts +1 -0
  308. package/dist/types/components.d.ts +0 -8
  309. package/dist/types/environment.d.ts +8 -0
  310. package/dist/types/scripts/zonos.d.ts +6 -0
  311. package/dist/types/types/checkout/CheckoutConfig.d.ts +3 -1
  312. package/dist/types/types/generated/graphql.customer.types.d.ts +104 -7
  313. package/dist/types/types/generated/graphql.customer.types.ts +138 -7
  314. package/dist/types/types/index.d.ts +1 -0
  315. package/dist/zonos-elements/assets/RemoveIcon.svg +1 -1
  316. package/dist/zonos-elements/index.esm.js +1 -3
  317. package/dist/zonos-elements/p-0190f7c4.entry.js +1 -0
  318. package/dist/zonos-elements/p-0636859b.js +1 -0
  319. package/dist/zonos-elements/p-08695f4e.js +1 -0
  320. package/dist/zonos-elements/p-0a788f68.entry.js +1 -0
  321. package/dist/zonos-elements/p-0e0b46a5.js +1 -0
  322. package/dist/zonos-elements/p-0f7233fd.system.entry.js +1 -0
  323. package/dist/zonos-elements/p-15b71f0b.system.entry.js +1 -0
  324. package/dist/zonos-elements/p-23204b78.system.entry.js +1 -0
  325. package/dist/zonos-elements/p-23b0b4a2.system.entry.js +1 -0
  326. package/dist/zonos-elements/{classes-ce25a814.system.js → p-23e7c655.system.js} +1 -2
  327. package/dist/zonos-elements/p-2b6325ab.entry.js +1 -0
  328. package/dist/zonos-elements/p-2c20c082.entry.js +1 -0
  329. package/dist/zonos-elements/p-30fd29fb.js +1 -0
  330. package/dist/zonos-elements/p-343071d5.entry.js +1 -0
  331. package/dist/zonos-elements/p-36425562.system.entry.js +1 -0
  332. package/dist/zonos-elements/p-37db3842.system.entry.js +1 -0
  333. package/dist/zonos-elements/p-37fc9f6b.entry.js +1 -0
  334. package/dist/zonos-elements/p-42ba069d.system.js +1 -0
  335. package/dist/zonos-elements/p-43a25dab.entry.js +1 -0
  336. package/dist/zonos-elements/p-4524a84f.system.entry.js +1 -0
  337. package/dist/zonos-elements/{getHasMoreSpaceOnRight-5a9efd60.system.js → p-4a5096d2.system.js} +1 -2
  338. package/dist/zonos-elements/{isColorVariable-be454101.system.js → p-64fdb7b6.system.js} +1 -2
  339. package/dist/zonos-elements/{index-87193773.system.js → p-68d06767.system.js} +1 -2
  340. package/dist/zonos-elements/p-6d82986c.system.entry.js +1 -0
  341. package/dist/zonos-elements/p-6dcd752e.system.js +1 -0
  342. package/dist/zonos-elements/p-6df1eaee.js +1 -0
  343. package/dist/zonos-elements/p-6e7cd3f7.entry.js +1 -0
  344. package/dist/zonos-elements/p-79f9e330.system.js +1 -0
  345. package/dist/zonos-elements/p-7bacecf7.entry.js +1 -0
  346. package/dist/zonos-elements/p-824395fd.system.entry.js +1 -0
  347. package/dist/zonos-elements/p-85ab35c9.system.js +1 -0
  348. package/dist/zonos-elements/p-87f324c5.entry.js +1 -0
  349. package/dist/zonos-elements/p-8a75b765.system.entry.js +1 -0
  350. package/dist/zonos-elements/p-8c867835.system.js +1 -0
  351. package/dist/zonos-elements/p-914ce305.system.entry.js +1 -0
  352. package/dist/zonos-elements/p-9688bb12.entry.js +1 -0
  353. package/dist/zonos-elements/p-96a3c767.entry.js +1 -0
  354. package/dist/zonos-elements/p-98105ede.entry.js +1 -0
  355. package/dist/zonos-elements/p-98a6e093.system.entry.js +1 -0
  356. package/dist/zonos-elements/p-9adf546f.system.entry.js +1 -0
  357. package/dist/zonos-elements/p-9b86e655.system.entry.js +1 -0
  358. package/dist/zonos-elements/p-9dc9cbc8.entry.js +1 -0
  359. package/dist/zonos-elements/p-a20b97e9.system.entry.js +1 -0
  360. package/dist/zonos-elements/p-b4b7f705.js +1 -0
  361. package/dist/zonos-elements/p-b618cf03.entry.js +1 -0
  362. package/dist/zonos-elements/p-b64bbf38.system.js +1 -0
  363. package/dist/zonos-elements/p-b6c499d4.js +1 -0
  364. package/dist/zonos-elements/p-b75ffe64.system.entry.js +1 -0
  365. package/dist/zonos-elements/p-bb36a9f8.js +1 -0
  366. package/dist/zonos-elements/p-bf070bf6.js +1 -0
  367. package/dist/zonos-elements/p-c28157ec.system.entry.js +1 -0
  368. package/dist/zonos-elements/p-d43749bd.entry.js +1 -0
  369. package/dist/zonos-elements/p-dc8d7000.js +2 -0
  370. package/dist/zonos-elements/p-f23749e4.system.js +1 -0
  371. package/dist/zonos-elements/p-f8491335.system.js +1 -0
  372. package/dist/zonos-elements/p-f868ed42.entry.js +1 -0
  373. package/dist/zonos-elements/zonos-elements.esm.js +1 -20
  374. package/dist/zonos-elements/zonos-elements.js +1 -1
  375. package/package.json +1 -1
  376. package/dist/cjs/cart-a969ee0b.js.map +0 -1
  377. package/dist/cjs/classes-b7918f56.js.map +0 -1
  378. package/dist/cjs/getBorderRadius-ae52cae1.js.map +0 -1
  379. package/dist/cjs/getHasMoreSpaceOnRight-2855491b.js.map +0 -1
  380. package/dist/cjs/index-9542d2e7.js.map +0 -1
  381. package/dist/cjs/index.cjs.js.map +0 -1
  382. package/dist/cjs/isColorVariable-c1ed7303.js.map +0 -1
  383. package/dist/cjs/isDarkColor-e1a7bf45.js.map +0 -1
  384. package/dist/cjs/loader.cjs.js.map +0 -1
  385. package/dist/cjs/localization-d510574c.js.map +0 -1
  386. package/dist/cjs/submitGtag-4de4430f.js.map +0 -1
  387. package/dist/cjs/zonos-address_2.cjs.entry.js.map +0 -1
  388. package/dist/cjs/zonos-badge.cjs.entry.js.map +0 -1
  389. package/dist/cjs/zonos-banner.cjs.entry.js.map +0 -1
  390. package/dist/cjs/zonos-button_2.cjs.entry.js.map +0 -1
  391. package/dist/cjs/zonos-card_2.cjs.entry.js.map +0 -1
  392. package/dist/cjs/zonos-cart-items_10.cjs.entry.js.map +0 -1
  393. package/dist/cjs/zonos-checkout.cjs.entry.js.map +0 -1
  394. package/dist/cjs/zonos-component.cjs.entry.js.map +0 -1
  395. package/dist/cjs/zonos-controller.cjs.entry.js.map +0 -1
  396. package/dist/cjs/zonos-country-flag_4.cjs.entry.js.map +0 -1
  397. package/dist/cjs/zonos-elements.cjs.js.map +0 -1
  398. package/dist/cjs/zonos-hello-dialog.cjs.entry.js.map +0 -1
  399. package/dist/cjs/zonos-hello.cjs.entry.js.map +0 -1
  400. package/dist/cjs/zonos-icon.cjs.entry.js.map +0 -1
  401. package/dist/cjs/zonos-notification.cjs.entry.js.map +0 -1
  402. package/dist/cjs/zonos-payment.cjs.entry.js.map +0 -1
  403. package/dist/cjs/zonos-shipping-rich-radio.cjs.entry.js.map +0 -1
  404. package/dist/cjs/zonos-text.cjs.entry.js.map +0 -1
  405. package/dist/cjs/zonosStore-d9cdaec6.js.map +0 -1
  406. package/dist/collection/components/checkout/zonos-checkout/zonos-cart-items/zonos-cart-items.js.map +0 -1
  407. package/dist/collection/components/checkout/zonos-checkout/zonos-cart-subtotal/zonos-cart-subtotal.js.map +0 -1
  408. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-finish/zonos-checkout-finish.js.map +0 -1
  409. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout-payment/zonos-checkout-payment.js.map +0 -1
  410. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout.js.map +0 -1
  411. package/dist/collection/components/checkout/zonos-checkout/zonos-customer-info/zonos-customer-info.js.map +0 -1
  412. package/dist/collection/components/checkout/zonos-checkout/zonos-review/zonos-review.js.map +0 -1
  413. package/dist/collection/components/checkout/zonos-checkout/zonos-shipping/zonos-shipping.js.map +0 -1
  414. package/dist/collection/components/common/countries.js.map +0 -1
  415. package/dist/collection/components/common/zonos-badge/zonos-badge.js.map +0 -1
  416. package/dist/collection/components/common/zonos-banner/zonos-banner.js.map +0 -1
  417. package/dist/collection/components/common/zonos-button/zonos-button.js.map +0 -1
  418. package/dist/collection/components/common/zonos-card/zonos-card.js.map +0 -1
  419. package/dist/collection/components/common/zonos-collapse/zonos-collapse.js.map +0 -1
  420. package/dist/collection/components/common/zonos-country-flag/zonos-country-flag.js.map +0 -1
  421. package/dist/collection/components/common/zonos-country-select/zonos-country-select.js.map +0 -1
  422. package/dist/collection/components/common/zonos-custom-message/zonos-custom-message.js.map +0 -1
  423. package/dist/collection/components/common/zonos-dialog/zonos-dialog.js.map +0 -1
  424. package/dist/collection/components/common/zonos-icon/zonos-icon.js.map +0 -1
  425. package/dist/collection/components/common/zonos-logo/zonos-logo.js.map +0 -1
  426. package/dist/collection/components/common/zonos-notification/zonos-notification.js.map +0 -1
  427. package/dist/collection/components/common/zonos-shipping-rich-radio/zonos-shipping-rich-radio.js.map +0 -1
  428. package/dist/collection/components/common/zonos-spinner/zonos-spinner.js.map +0 -1
  429. package/dist/collection/components/common/zonos-text/zonos-text.js.map +0 -1
  430. package/dist/collection/components/common/zonos-v-stack/zonos-v-stack.js.map +0 -1
  431. package/dist/collection/components/component-template/zonos-component/zonos-component.js.map +0 -1
  432. package/dist/collection/components/hello/zonos-hello/zonos-hello.js.map +0 -1
  433. package/dist/collection/components/hello/zonos-hello-dialog/zonos-hello-dialog-footer/zonos-hello-dialog-footer.js.map +0 -1
  434. package/dist/collection/components/hello/zonos-hello-dialog/zonos-hello-dialog.js.map +0 -1
  435. package/dist/collection/components/main/zonos-controller.js.map +0 -1
  436. package/dist/collection/components/store/checkout/cart.js.map +0 -1
  437. package/dist/collection/components/store/checkout/stripe.js.map +0 -1
  438. package/dist/collection/components/store/hello/localization.js.map +0 -1
  439. package/dist/collection/components/store/translationStore/strings.arabic.js.map +0 -1
  440. package/dist/collection/components/store/translationStore/strings.base.js.map +0 -1
  441. package/dist/collection/components/store/translationStore/strings.chinese.js.map +0 -1
  442. package/dist/collection/components/store/translationStore/strings.danish.js.map +0 -1
  443. package/dist/collection/components/store/translationStore/strings.dutch.js.map +0 -1
  444. package/dist/collection/components/store/translationStore/strings.french.js.map +0 -1
  445. package/dist/collection/components/store/translationStore/strings.german.js.map +0 -1
  446. package/dist/collection/components/store/translationStore/strings.hebrew.js.map +0 -1
  447. package/dist/collection/components/store/translationStore/strings.indonesian.js.map +0 -1
  448. package/dist/collection/components/store/translationStore/strings.italian.js.map +0 -1
  449. package/dist/collection/components/store/translationStore/strings.japanese.js.map +0 -1
  450. package/dist/collection/components/store/translationStore/strings.korean.js.map +0 -1
  451. package/dist/collection/components/store/translationStore/strings.norwegian.js.map +0 -1
  452. package/dist/collection/components/store/translationStore/strings.polish.js.map +0 -1
  453. package/dist/collection/components/store/translationStore/strings.portuguese.js.map +0 -1
  454. package/dist/collection/components/store/translationStore/strings.russian.js.map +0 -1
  455. package/dist/collection/components/store/translationStore/strings.spanish.js.map +0 -1
  456. package/dist/collection/components/store/translationStore/strings.swedish.js.map +0 -1
  457. package/dist/collection/components/store/translationStore/strings.turkish.js.map +0 -1
  458. package/dist/collection/components/store/translationStore/strings.vietnamese.js.map +0 -1
  459. package/dist/collection/components/store/translationStore.js.map +0 -1
  460. package/dist/collection/components/store/zonosStore.js.map +0 -1
  461. package/dist/collection/components/stripe/zonos-address/zonos-address.js.map +0 -1
  462. package/dist/collection/components/stripe/zonos-link-authentication/zonos-link-authentication.js.map +0 -1
  463. package/dist/collection/components/stripe/zonos-payment/zonos-payment.js.map +0 -1
  464. package/dist/collection/components/utils/addDays.js.map +0 -1
  465. package/dist/collection/components/utils/api/calculateLandedCost.js.map +0 -1
  466. package/dist/collection/components/utils/api/checkItemRestrictions.js.map +0 -1
  467. package/dist/collection/components/utils/api/getCountries.js.map +0 -1
  468. package/dist/collection/components/utils/api/getCountryLandedCost.js.map +0 -1
  469. package/dist/collection/components/utils/api/getExchangeRate.js.map +0 -1
  470. package/dist/collection/components/utils/api/getLocaleMessages.js.map +0 -1
  471. package/dist/collection/components/utils/api/getLocalization.js.map +0 -1
  472. package/dist/collection/components/utils/api/getShippingZones.js.map +0 -1
  473. package/dist/collection/components/utils/api/getZonosSetting.js.map +0 -1
  474. package/dist/collection/components/utils/api/prepCalculateLandedCost.js.map +0 -1
  475. package/dist/collection/components/utils/changeDeepProperty.js.map +0 -1
  476. package/dist/collection/components/utils/changeDeepPropertyAtIndex.js.map +0 -1
  477. package/dist/collection/components/utils/checkout/initCheckout.js.map +0 -1
  478. package/dist/collection/components/utils/checkout/isCheckoutMobile.js.map +0 -1
  479. package/dist/collection/components/utils/classes.js.map +0 -1
  480. package/dist/collection/components/utils/darkenColor.js.map +0 -1
  481. package/dist/collection/components/utils/formatCurrency.js.map +0 -1
  482. package/dist/collection/components/utils/formatDate.js.map +0 -1
  483. package/dist/collection/components/utils/getBorderRadius.js.map +0 -1
  484. package/dist/collection/components/utils/getButtonTheme.js.map +0 -1
  485. package/dist/collection/components/utils/getDaysDifference.js.map +0 -1
  486. package/dist/collection/components/utils/handleFetch.js.map +0 -1
  487. package/dist/collection/components/utils/hello/currencyConversion/currencyConvert.js.map +0 -1
  488. package/dist/collection/components/utils/hello/currencyConversion/currencyConvertAndFormat.js.map +0 -1
  489. package/dist/collection/components/utils/hello/currencyConversion/currencyDisplay.js.map +0 -1
  490. package/dist/collection/components/utils/hello/currencyConversion/currencyFormat.js.map +0 -1
  491. package/dist/collection/components/utils/hello/currencyConversion/defaultCurrencyConverter.js.map +0 -1
  492. package/dist/collection/components/utils/hello/currencyConversion/getCurrencyCode.js.map +0 -1
  493. package/dist/collection/components/utils/hello/currencyConversion/getCurrencyElements.js.map +0 -1
  494. package/dist/collection/components/utils/hello/currencyConversion/getInitialElementAmount.js.map +0 -1
  495. package/dist/collection/components/utils/hello/currencyConversion/getLanguageCode.js.map +0 -1
  496. package/dist/collection/components/utils/hello/detectItemRestrictions.js.map +0 -1
  497. package/dist/collection/components/utils/hello/getCurrentHelloLocalePage.js.map +0 -1
  498. package/dist/collection/components/utils/hello/getHasMoreSpaceOnRight.js.map +0 -1
  499. package/dist/collection/components/utils/hello/getProductsOnPage.js.map +0 -1
  500. package/dist/collection/components/utils/hello/initHello.js.map +0 -1
  501. package/dist/collection/components/utils/hello/setZonosCountryUrlParam.js.map +0 -1
  502. package/dist/collection/components/utils/isColorVariable.js.map +0 -1
  503. package/dist/collection/components/utils/isDarkColor.js.map +0 -1
  504. package/dist/collection/components/utils/isValidSelector.js.map +0 -1
  505. package/dist/collection/components/utils/jsonParse.js.map +0 -1
  506. package/dist/collection/components/utils/lightenColor.js.map +0 -1
  507. package/dist/collection/components/utils/logging/log.js.map +0 -1
  508. package/dist/collection/components/utils/logging/logError.js.map +0 -1
  509. package/dist/collection/components/utils/mergeConfig.js.map +0 -1
  510. package/dist/collection/components/utils/submitGtag.js.map +0 -1
  511. package/dist/collection/environment.js.map +0 -1
  512. package/dist/collection/index.js.map +0 -1
  513. package/dist/collection/scripts/loadStripe.js.map +0 -1
  514. package/dist/collection/scripts/stripe.js.map +0 -1
  515. package/dist/collection/scripts/zonos.js.map +0 -1
  516. package/dist/collection/styles/stripe/addressRuleStyle.js.map +0 -1
  517. package/dist/collection/styles/stripe/defaultVariable.js.map +0 -1
  518. package/dist/collection/types/ICountryJson.js.map +0 -1
  519. package/dist/collection/types/JsonError.js.map +0 -1
  520. package/dist/collection/types/NoInfer.js.map +0 -1
  521. package/dist/collection/types/Translation.js.map +0 -1
  522. package/dist/collection/types/checkout/CheckoutConfig.js.map +0 -1
  523. package/dist/collection/types/checkout/api/CalculateLandedCostRequest.js.map +0 -1
  524. package/dist/collection/types/generated/graphql.customer.types.js.map +0 -1
  525. package/dist/collection/types/generated/graphql.frontend.types.js.map +0 -1
  526. package/dist/collection/types/hello/HelloConfig.js.map +0 -1
  527. package/dist/collection/types/hello/Product.js.map +0 -1
  528. package/dist/collection/types/hello/RestrictedItem.js.map +0 -1
  529. package/dist/collection/types/index.js.map +0 -1
  530. package/dist/collection/types/online-store/OnlineStoreConfig.js.map +0 -1
  531. package/dist/collection/types/stripe/Apperance.js.map +0 -1
  532. package/dist/collection/types/styles/Color.js.map +0 -1
  533. package/dist/collection/types/styles/GridSpacing.js.map +0 -1
  534. package/dist/collection/types/styles/Text.js.map +0 -1
  535. package/dist/collection/types/utils/deep/IDeepKeyof.js.map +0 -1
  536. package/dist/collection/types/utils/deep/IDeepKeyofAtIndex.js.map +0 -1
  537. package/dist/collection/utils/format.js.map +0 -1
  538. package/dist/collection/utils/generateVercelDeployUrl.js.map +0 -1
  539. package/dist/components/classes.js.map +0 -1
  540. package/dist/components/formatCurrency.js.map +0 -1
  541. package/dist/components/getBorderRadius.js.map +0 -1
  542. package/dist/components/index.js.map +0 -1
  543. package/dist/components/isColorVariable.js.map +0 -1
  544. package/dist/components/isDarkColor.js.map +0 -1
  545. package/dist/components/localization.js.map +0 -1
  546. package/dist/components/stripe.js +0 -598
  547. package/dist/components/stripe.js.map +0 -1
  548. package/dist/components/submitGtag.js.map +0 -1
  549. package/dist/components/zonos-address.js.map +0 -1
  550. package/dist/components/zonos-address2.js.map +0 -1
  551. package/dist/components/zonos-badge.js.map +0 -1
  552. package/dist/components/zonos-badge2.js.map +0 -1
  553. package/dist/components/zonos-banner.js.map +0 -1
  554. package/dist/components/zonos-banner2.js.map +0 -1
  555. package/dist/components/zonos-button.js.map +0 -1
  556. package/dist/components/zonos-button2.js.map +0 -1
  557. package/dist/components/zonos-card.js.map +0 -1
  558. package/dist/components/zonos-card2.js.map +0 -1
  559. package/dist/components/zonos-cart-items.js.map +0 -1
  560. package/dist/components/zonos-cart-items2.js.map +0 -1
  561. package/dist/components/zonos-cart-subtotal.js.map +0 -1
  562. package/dist/components/zonos-cart-subtotal2.js.map +0 -1
  563. package/dist/components/zonos-checkout-finish.js.map +0 -1
  564. package/dist/components/zonos-checkout-finish2.js.map +0 -1
  565. package/dist/components/zonos-checkout-payment.js.map +0 -1
  566. package/dist/components/zonos-checkout-payment2.js.map +0 -1
  567. package/dist/components/zonos-checkout.js.map +0 -1
  568. package/dist/components/zonos-collapse.js.map +0 -1
  569. package/dist/components/zonos-collapse2.js.map +0 -1
  570. package/dist/components/zonos-component.js.map +0 -1
  571. package/dist/components/zonos-controller.js.map +0 -1
  572. package/dist/components/zonos-country-flag.js.map +0 -1
  573. package/dist/components/zonos-country-flag2.js.map +0 -1
  574. package/dist/components/zonos-country-select.js.map +0 -1
  575. package/dist/components/zonos-country-select2.js.map +0 -1
  576. package/dist/components/zonos-custom-message.js.map +0 -1
  577. package/dist/components/zonos-custom-message2.js.map +0 -1
  578. package/dist/components/zonos-customer-info.js.map +0 -1
  579. package/dist/components/zonos-customer-info2.js.map +0 -1
  580. package/dist/components/zonos-dialog.js.map +0 -1
  581. package/dist/components/zonos-dialog2.js.map +0 -1
  582. package/dist/components/zonos-hello-dialog-footer.js.map +0 -1
  583. package/dist/components/zonos-hello-dialog-footer2.js.map +0 -1
  584. package/dist/components/zonos-hello-dialog.js.map +0 -1
  585. package/dist/components/zonos-hello-dialog2.js.map +0 -1
  586. package/dist/components/zonos-hello.js.map +0 -1
  587. package/dist/components/zonos-icon.js.map +0 -1
  588. package/dist/components/zonos-icon2.js.map +0 -1
  589. package/dist/components/zonos-link-authentication.js.map +0 -1
  590. package/dist/components/zonos-link-authentication2.js.map +0 -1
  591. package/dist/components/zonos-logo.js.map +0 -1
  592. package/dist/components/zonos-logo2.js.map +0 -1
  593. package/dist/components/zonos-notification.js.map +0 -1
  594. package/dist/components/zonos-notification2.js.map +0 -1
  595. package/dist/components/zonos-payment.js.map +0 -1
  596. package/dist/components/zonos-payment2.js.map +0 -1
  597. package/dist/components/zonos-review.js.map +0 -1
  598. package/dist/components/zonos-review2.js.map +0 -1
  599. package/dist/components/zonos-shipping-rich-radio.js.map +0 -1
  600. package/dist/components/zonos-shipping-rich-radio2.js.map +0 -1
  601. package/dist/components/zonos-shipping.js.map +0 -1
  602. package/dist/components/zonos-shipping2.js.map +0 -1
  603. package/dist/components/zonos-spinner.js.map +0 -1
  604. package/dist/components/zonos-spinner2.js.map +0 -1
  605. package/dist/components/zonos-text.js.map +0 -1
  606. package/dist/components/zonos-text2.js.map +0 -1
  607. package/dist/components/zonos-v-stack.js.map +0 -1
  608. package/dist/components/zonos-v-stack2.js.map +0 -1
  609. package/dist/components/zonosStore.js.map +0 -1
  610. package/dist/esm/cart-d00e1acb.js.map +0 -1
  611. package/dist/esm/classes-0d95c529.js.map +0 -1
  612. package/dist/esm/getBorderRadius-e8ad5967.js.map +0 -1
  613. package/dist/esm/getHasMoreSpaceOnRight-feba1ae2.js.map +0 -1
  614. package/dist/esm/index-d1aa9293.js.map +0 -1
  615. package/dist/esm/index.js.map +0 -1
  616. package/dist/esm/isColorVariable-4cda28c9.js.map +0 -1
  617. package/dist/esm/isDarkColor-3bb345f4.js +0 -1197
  618. package/dist/esm/isDarkColor-3bb345f4.js.map +0 -1
  619. package/dist/esm/loader.js.map +0 -1
  620. package/dist/esm/localization-1d92a557.js +0 -3561
  621. package/dist/esm/localization-1d92a557.js.map +0 -1
  622. package/dist/esm/submitGtag-85914088.js.map +0 -1
  623. package/dist/esm/zonos-address_2.entry.js.map +0 -1
  624. package/dist/esm/zonos-badge.entry.js.map +0 -1
  625. package/dist/esm/zonos-banner.entry.js.map +0 -1
  626. package/dist/esm/zonos-button_2.entry.js.map +0 -1
  627. package/dist/esm/zonos-card_2.entry.js.map +0 -1
  628. package/dist/esm/zonos-cart-items_10.entry.js.map +0 -1
  629. package/dist/esm/zonos-checkout.entry.js.map +0 -1
  630. package/dist/esm/zonos-component.entry.js.map +0 -1
  631. package/dist/esm/zonos-controller.entry.js.map +0 -1
  632. package/dist/esm/zonos-country-flag_4.entry.js.map +0 -1
  633. package/dist/esm/zonos-elements.js.map +0 -1
  634. package/dist/esm/zonos-hello-dialog.entry.js.map +0 -1
  635. package/dist/esm/zonos-hello.entry.js.map +0 -1
  636. package/dist/esm/zonos-icon.entry.js.map +0 -1
  637. package/dist/esm/zonos-notification.entry.js.map +0 -1
  638. package/dist/esm/zonos-payment.entry.js.map +0 -1
  639. package/dist/esm/zonos-shipping-rich-radio.entry.js.map +0 -1
  640. package/dist/esm/zonos-text.entry.js.map +0 -1
  641. package/dist/esm/zonosStore-1c9c7d76.js +0 -2623
  642. package/dist/esm/zonosStore-1c9c7d76.js.map +0 -1
  643. package/dist/esm-es5/cart-d00e1acb.js +0 -2
  644. package/dist/esm-es5/cart-d00e1acb.js.map +0 -1
  645. package/dist/esm-es5/classes-0d95c529.js.map +0 -1
  646. package/dist/esm-es5/getBorderRadius-e8ad5967.js +0 -2
  647. package/dist/esm-es5/getBorderRadius-e8ad5967.js.map +0 -1
  648. package/dist/esm-es5/getHasMoreSpaceOnRight-feba1ae2.js.map +0 -1
  649. package/dist/esm-es5/index-d1aa9293.js.map +0 -1
  650. package/dist/esm-es5/index.js.map +0 -1
  651. package/dist/esm-es5/isColorVariable-4cda28c9.js.map +0 -1
  652. package/dist/esm-es5/isDarkColor-3bb345f4.js.map +0 -1
  653. package/dist/esm-es5/loader.js.map +0 -1
  654. package/dist/esm-es5/localization-1d92a557.js.map +0 -1
  655. package/dist/esm-es5/submitGtag-85914088.js.map +0 -1
  656. package/dist/esm-es5/zonos-address_2.entry.js.map +0 -1
  657. package/dist/esm-es5/zonos-badge.entry.js.map +0 -1
  658. package/dist/esm-es5/zonos-banner.entry.js.map +0 -1
  659. package/dist/esm-es5/zonos-button_2.entry.js.map +0 -1
  660. package/dist/esm-es5/zonos-card_2.entry.js.map +0 -1
  661. package/dist/esm-es5/zonos-cart-items_10.entry.js.map +0 -1
  662. package/dist/esm-es5/zonos-checkout.entry.js.map +0 -1
  663. package/dist/esm-es5/zonos-component.entry.js.map +0 -1
  664. package/dist/esm-es5/zonos-controller.entry.js.map +0 -1
  665. package/dist/esm-es5/zonos-country-flag_4.entry.js.map +0 -1
  666. package/dist/esm-es5/zonos-elements.js.map +0 -1
  667. package/dist/esm-es5/zonos-hello-dialog.entry.js.map +0 -1
  668. package/dist/esm-es5/zonos-hello.entry.js.map +0 -1
  669. package/dist/esm-es5/zonos-icon.entry.js.map +0 -1
  670. package/dist/esm-es5/zonos-notification.entry.js.map +0 -1
  671. package/dist/esm-es5/zonos-payment.entry.js.map +0 -1
  672. package/dist/esm-es5/zonos-shipping-rich-radio.entry.js.map +0 -1
  673. package/dist/esm-es5/zonos-text.entry.js.map +0 -1
  674. package/dist/esm-es5/zonosStore-1c9c7d76.js.map +0 -1
  675. package/dist/zonos-elements/cart-c641ddaf.system.js +0 -2
  676. package/dist/zonos-elements/cart-c641ddaf.system.js.map +0 -1
  677. package/dist/zonos-elements/cart-d00e1acb.js.map +0 -1
  678. package/dist/zonos-elements/classes-0d95c529.js +0 -14
  679. package/dist/zonos-elements/classes-0d95c529.js.map +0 -1
  680. package/dist/zonos-elements/classes-ce25a814.system.js.map +0 -1
  681. package/dist/zonos-elements/getBorderRadius-b59c3ada.system.js +0 -2
  682. package/dist/zonos-elements/getBorderRadius-b59c3ada.system.js.map +0 -1
  683. package/dist/zonos-elements/getBorderRadius-e8ad5967.js +0 -18
  684. package/dist/zonos-elements/getBorderRadius-e8ad5967.js.map +0 -1
  685. package/dist/zonos-elements/getHasMoreSpaceOnRight-5a9efd60.system.js.map +0 -1
  686. package/dist/zonos-elements/getHasMoreSpaceOnRight-feba1ae2.js +0 -10
  687. package/dist/zonos-elements/getHasMoreSpaceOnRight-feba1ae2.js.map +0 -1
  688. package/dist/zonos-elements/index-87193773.system.js.map +0 -1
  689. package/dist/zonos-elements/index-d1aa9293.js +0 -1884
  690. package/dist/zonos-elements/index-d1aa9293.js.map +0 -1
  691. package/dist/zonos-elements/index.esm.js.map +0 -1
  692. package/dist/zonos-elements/index.system.js +0 -2
  693. package/dist/zonos-elements/index.system.js.map +0 -1
  694. package/dist/zonos-elements/isColorVariable-4cda28c9.js +0 -16
  695. package/dist/zonos-elements/isColorVariable-4cda28c9.js.map +0 -1
  696. package/dist/zonos-elements/isColorVariable-be454101.system.js.map +0 -1
  697. package/dist/zonos-elements/isDarkColor-231502d4.system.js +0 -2
  698. package/dist/zonos-elements/isDarkColor-231502d4.system.js.map +0 -1
  699. package/dist/zonos-elements/isDarkColor-3bb345f4.js.map +0 -1
  700. package/dist/zonos-elements/localization-1d92a557.js.map +0 -1
  701. package/dist/zonos-elements/localization-a6b6a5a5.system.js +0 -2
  702. package/dist/zonos-elements/localization-a6b6a5a5.system.js.map +0 -1
  703. package/dist/zonos-elements/submitGtag-764af8c4.system.js +0 -2
  704. package/dist/zonos-elements/submitGtag-764af8c4.system.js.map +0 -1
  705. package/dist/zonos-elements/submitGtag-85914088.js +0 -26
  706. package/dist/zonos-elements/submitGtag-85914088.js.map +0 -1
  707. package/dist/zonos-elements/zonos-address_2.entry.js +0 -121
  708. package/dist/zonos-elements/zonos-address_2.entry.js.map +0 -1
  709. package/dist/zonos-elements/zonos-address_2.system.entry.js +0 -2
  710. package/dist/zonos-elements/zonos-address_2.system.entry.js.map +0 -1
  711. package/dist/zonos-elements/zonos-badge.entry.js +0 -32
  712. package/dist/zonos-elements/zonos-badge.entry.js.map +0 -1
  713. package/dist/zonos-elements/zonos-badge.system.entry.js +0 -2
  714. package/dist/zonos-elements/zonos-badge.system.entry.js.map +0 -1
  715. package/dist/zonos-elements/zonos-banner.entry.js +0 -64
  716. package/dist/zonos-elements/zonos-banner.entry.js.map +0 -1
  717. package/dist/zonos-elements/zonos-banner.system.entry.js +0 -2
  718. package/dist/zonos-elements/zonos-banner.system.entry.js.map +0 -1
  719. package/dist/zonos-elements/zonos-button_2.entry.js +0 -124
  720. package/dist/zonos-elements/zonos-button_2.entry.js.map +0 -1
  721. package/dist/zonos-elements/zonos-button_2.system.entry.js +0 -2
  722. package/dist/zonos-elements/zonos-button_2.system.entry.js.map +0 -1
  723. package/dist/zonos-elements/zonos-card_2.entry.js +0 -42
  724. package/dist/zonos-elements/zonos-card_2.entry.js.map +0 -1
  725. package/dist/zonos-elements/zonos-card_2.system.entry.js +0 -2
  726. package/dist/zonos-elements/zonos-card_2.system.entry.js.map +0 -1
  727. package/dist/zonos-elements/zonos-cart-items_10.entry.js +0 -494
  728. package/dist/zonos-elements/zonos-cart-items_10.entry.js.map +0 -1
  729. package/dist/zonos-elements/zonos-cart-items_10.system.entry.js +0 -2
  730. package/dist/zonos-elements/zonos-cart-items_10.system.entry.js.map +0 -1
  731. package/dist/zonos-elements/zonos-checkout.entry.js +0 -337
  732. package/dist/zonos-elements/zonos-checkout.entry.js.map +0 -1
  733. package/dist/zonos-elements/zonos-checkout.system.entry.js +0 -2
  734. package/dist/zonos-elements/zonos-checkout.system.entry.js.map +0 -1
  735. package/dist/zonos-elements/zonos-component.entry.js +0 -27
  736. package/dist/zonos-elements/zonos-component.entry.js.map +0 -1
  737. package/dist/zonos-elements/zonos-component.system.entry.js +0 -2
  738. package/dist/zonos-elements/zonos-component.system.entry.js.map +0 -1
  739. package/dist/zonos-elements/zonos-controller.entry.js +0 -165
  740. package/dist/zonos-elements/zonos-controller.entry.js.map +0 -1
  741. package/dist/zonos-elements/zonos-controller.system.entry.js +0 -2
  742. package/dist/zonos-elements/zonos-controller.system.entry.js.map +0 -1
  743. package/dist/zonos-elements/zonos-country-flag_4.entry.js +0 -1895
  744. package/dist/zonos-elements/zonos-country-flag_4.entry.js.map +0 -1
  745. package/dist/zonos-elements/zonos-country-flag_4.system.entry.js +0 -2
  746. package/dist/zonos-elements/zonos-country-flag_4.system.entry.js.map +0 -1
  747. package/dist/zonos-elements/zonos-elements.esm.js.map +0 -1
  748. package/dist/zonos-elements/zonos-elements.system.js +0 -2
  749. package/dist/zonos-elements/zonos-elements.system.js.map +0 -1
  750. package/dist/zonos-elements/zonos-hello-dialog.entry.js +0 -115
  751. package/dist/zonos-elements/zonos-hello-dialog.entry.js.map +0 -1
  752. package/dist/zonos-elements/zonos-hello-dialog.system.entry.js +0 -2
  753. package/dist/zonos-elements/zonos-hello-dialog.system.entry.js.map +0 -1
  754. package/dist/zonos-elements/zonos-hello.entry.js +0 -696
  755. package/dist/zonos-elements/zonos-hello.entry.js.map +0 -1
  756. package/dist/zonos-elements/zonos-hello.system.entry.js +0 -2
  757. package/dist/zonos-elements/zonos-hello.system.entry.js.map +0 -1
  758. package/dist/zonos-elements/zonos-icon.entry.js +0 -30
  759. package/dist/zonos-elements/zonos-icon.entry.js.map +0 -1
  760. package/dist/zonos-elements/zonos-icon.system.entry.js +0 -2
  761. package/dist/zonos-elements/zonos-icon.system.entry.js.map +0 -1
  762. package/dist/zonos-elements/zonos-notification.entry.js +0 -67
  763. package/dist/zonos-elements/zonos-notification.entry.js.map +0 -1
  764. package/dist/zonos-elements/zonos-notification.system.entry.js +0 -2
  765. package/dist/zonos-elements/zonos-notification.system.entry.js.map +0 -1
  766. package/dist/zonos-elements/zonos-payment.entry.js +0 -56
  767. package/dist/zonos-elements/zonos-payment.entry.js.map +0 -1
  768. package/dist/zonos-elements/zonos-payment.system.entry.js +0 -2
  769. package/dist/zonos-elements/zonos-payment.system.entry.js.map +0 -1
  770. package/dist/zonos-elements/zonos-shipping-rich-radio.entry.js +0 -50
  771. package/dist/zonos-elements/zonos-shipping-rich-radio.entry.js.map +0 -1
  772. package/dist/zonos-elements/zonos-shipping-rich-radio.system.entry.js +0 -2
  773. package/dist/zonos-elements/zonos-shipping-rich-radio.system.entry.js.map +0 -1
  774. package/dist/zonos-elements/zonos-text.entry.js +0 -156
  775. package/dist/zonos-elements/zonos-text.entry.js.map +0 -1
  776. package/dist/zonos-elements/zonos-text.system.entry.js +0 -2
  777. package/dist/zonos-elements/zonos-text.system.entry.js.map +0 -1
  778. package/dist/zonos-elements/zonosStore-1c9c7d76.js.map +0 -1
  779. package/dist/zonos-elements/zonosStore-e5c545ea.system.js +0 -2
  780. package/dist/zonos-elements/zonosStore-e5c545ea.system.js.map +0 -1
@@ -1,1197 +0,0 @@
1
- import { a as createCommonjsModule, b as commonjsGlobal } from './zonosStore-1c9c7d76.js';
2
-
3
- var tinycolor = createCommonjsModule(function (module, exports) {
4
- // This file is autogenerated. It's used to publish CJS to npm.
5
- (function (global, factory) {
6
- module.exports = factory() ;
7
- })(commonjsGlobal, (function () {
8
- function _typeof(obj) {
9
- "@babel/helpers - typeof";
10
-
11
- return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
12
- return typeof obj;
13
- } : function (obj) {
14
- return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
15
- }, _typeof(obj);
16
- }
17
-
18
- // https://github.com/bgrins/TinyColor
19
- // Brian Grinstead, MIT License
20
-
21
- var trimLeft = /^\s+/;
22
- var trimRight = /\s+$/;
23
- function tinycolor(color, opts) {
24
- color = color ? color : "";
25
- opts = opts || {};
26
-
27
- // If input is already a tinycolor, return itself
28
- if (color instanceof tinycolor) {
29
- return color;
30
- }
31
- // If we are called as a function, call using new instead
32
- if (!(this instanceof tinycolor)) {
33
- return new tinycolor(color, opts);
34
- }
35
- var rgb = inputToRGB(color);
36
- this._originalInput = color, this._r = rgb.r, this._g = rgb.g, this._b = rgb.b, this._a = rgb.a, this._roundA = Math.round(100 * this._a) / 100, this._format = opts.format || rgb.format;
37
- this._gradientType = opts.gradientType;
38
-
39
- // Don't let the range of [0,255] come back in [0,1].
40
- // Potentially lose a little bit of precision here, but will fix issues where
41
- // .5 gets interpreted as half of the total, instead of half of 1
42
- // If it was supposed to be 128, this was already taken care of by `inputToRgb`
43
- if (this._r < 1) this._r = Math.round(this._r);
44
- if (this._g < 1) this._g = Math.round(this._g);
45
- if (this._b < 1) this._b = Math.round(this._b);
46
- this._ok = rgb.ok;
47
- }
48
- tinycolor.prototype = {
49
- isDark: function isDark() {
50
- return this.getBrightness() < 128;
51
- },
52
- isLight: function isLight() {
53
- return !this.isDark();
54
- },
55
- isValid: function isValid() {
56
- return this._ok;
57
- },
58
- getOriginalInput: function getOriginalInput() {
59
- return this._originalInput;
60
- },
61
- getFormat: function getFormat() {
62
- return this._format;
63
- },
64
- getAlpha: function getAlpha() {
65
- return this._a;
66
- },
67
- getBrightness: function getBrightness() {
68
- //http://www.w3.org/TR/AERT#color-contrast
69
- var rgb = this.toRgb();
70
- return (rgb.r * 299 + rgb.g * 587 + rgb.b * 114) / 1000;
71
- },
72
- getLuminance: function getLuminance() {
73
- //http://www.w3.org/TR/2008/REC-WCAG20-20081211/#relativeluminancedef
74
- var rgb = this.toRgb();
75
- var RsRGB, GsRGB, BsRGB, R, G, B;
76
- RsRGB = rgb.r / 255;
77
- GsRGB = rgb.g / 255;
78
- BsRGB = rgb.b / 255;
79
- if (RsRGB <= 0.03928) R = RsRGB / 12.92;else R = Math.pow((RsRGB + 0.055) / 1.055, 2.4);
80
- if (GsRGB <= 0.03928) G = GsRGB / 12.92;else G = Math.pow((GsRGB + 0.055) / 1.055, 2.4);
81
- if (BsRGB <= 0.03928) B = BsRGB / 12.92;else B = Math.pow((BsRGB + 0.055) / 1.055, 2.4);
82
- return 0.2126 * R + 0.7152 * G + 0.0722 * B;
83
- },
84
- setAlpha: function setAlpha(value) {
85
- this._a = boundAlpha(value);
86
- this._roundA = Math.round(100 * this._a) / 100;
87
- return this;
88
- },
89
- toHsv: function toHsv() {
90
- var hsv = rgbToHsv(this._r, this._g, this._b);
91
- return {
92
- h: hsv.h * 360,
93
- s: hsv.s,
94
- v: hsv.v,
95
- a: this._a
96
- };
97
- },
98
- toHsvString: function toHsvString() {
99
- var hsv = rgbToHsv(this._r, this._g, this._b);
100
- var h = Math.round(hsv.h * 360),
101
- s = Math.round(hsv.s * 100),
102
- v = Math.round(hsv.v * 100);
103
- return this._a == 1 ? "hsv(" + h + ", " + s + "%, " + v + "%)" : "hsva(" + h + ", " + s + "%, " + v + "%, " + this._roundA + ")";
104
- },
105
- toHsl: function toHsl() {
106
- var hsl = rgbToHsl(this._r, this._g, this._b);
107
- return {
108
- h: hsl.h * 360,
109
- s: hsl.s,
110
- l: hsl.l,
111
- a: this._a
112
- };
113
- },
114
- toHslString: function toHslString() {
115
- var hsl = rgbToHsl(this._r, this._g, this._b);
116
- var h = Math.round(hsl.h * 360),
117
- s = Math.round(hsl.s * 100),
118
- l = Math.round(hsl.l * 100);
119
- return this._a == 1 ? "hsl(" + h + ", " + s + "%, " + l + "%)" : "hsla(" + h + ", " + s + "%, " + l + "%, " + this._roundA + ")";
120
- },
121
- toHex: function toHex(allow3Char) {
122
- return rgbToHex(this._r, this._g, this._b, allow3Char);
123
- },
124
- toHexString: function toHexString(allow3Char) {
125
- return "#" + this.toHex(allow3Char);
126
- },
127
- toHex8: function toHex8(allow4Char) {
128
- return rgbaToHex(this._r, this._g, this._b, this._a, allow4Char);
129
- },
130
- toHex8String: function toHex8String(allow4Char) {
131
- return "#" + this.toHex8(allow4Char);
132
- },
133
- toRgb: function toRgb() {
134
- return {
135
- r: Math.round(this._r),
136
- g: Math.round(this._g),
137
- b: Math.round(this._b),
138
- a: this._a
139
- };
140
- },
141
- toRgbString: function toRgbString() {
142
- return this._a == 1 ? "rgb(" + Math.round(this._r) + ", " + Math.round(this._g) + ", " + Math.round(this._b) + ")" : "rgba(" + Math.round(this._r) + ", " + Math.round(this._g) + ", " + Math.round(this._b) + ", " + this._roundA + ")";
143
- },
144
- toPercentageRgb: function toPercentageRgb() {
145
- return {
146
- r: Math.round(bound01(this._r, 255) * 100) + "%",
147
- g: Math.round(bound01(this._g, 255) * 100) + "%",
148
- b: Math.round(bound01(this._b, 255) * 100) + "%",
149
- a: this._a
150
- };
151
- },
152
- toPercentageRgbString: function toPercentageRgbString() {
153
- return this._a == 1 ? "rgb(" + Math.round(bound01(this._r, 255) * 100) + "%, " + Math.round(bound01(this._g, 255) * 100) + "%, " + Math.round(bound01(this._b, 255) * 100) + "%)" : "rgba(" + Math.round(bound01(this._r, 255) * 100) + "%, " + Math.round(bound01(this._g, 255) * 100) + "%, " + Math.round(bound01(this._b, 255) * 100) + "%, " + this._roundA + ")";
154
- },
155
- toName: function toName() {
156
- if (this._a === 0) {
157
- return "transparent";
158
- }
159
- if (this._a < 1) {
160
- return false;
161
- }
162
- return hexNames[rgbToHex(this._r, this._g, this._b, true)] || false;
163
- },
164
- toFilter: function toFilter(secondColor) {
165
- var hex8String = "#" + rgbaToArgbHex(this._r, this._g, this._b, this._a);
166
- var secondHex8String = hex8String;
167
- var gradientType = this._gradientType ? "GradientType = 1, " : "";
168
- if (secondColor) {
169
- var s = tinycolor(secondColor);
170
- secondHex8String = "#" + rgbaToArgbHex(s._r, s._g, s._b, s._a);
171
- }
172
- return "progid:DXImageTransform.Microsoft.gradient(" + gradientType + "startColorstr=" + hex8String + ",endColorstr=" + secondHex8String + ")";
173
- },
174
- toString: function toString(format) {
175
- var formatSet = !!format;
176
- format = format || this._format;
177
- var formattedString = false;
178
- var hasAlpha = this._a < 1 && this._a >= 0;
179
- var needsAlphaFormat = !formatSet && hasAlpha && (format === "hex" || format === "hex6" || format === "hex3" || format === "hex4" || format === "hex8" || format === "name");
180
- if (needsAlphaFormat) {
181
- // Special case for "transparent", all other non-alpha formats
182
- // will return rgba when there is transparency.
183
- if (format === "name" && this._a === 0) {
184
- return this.toName();
185
- }
186
- return this.toRgbString();
187
- }
188
- if (format === "rgb") {
189
- formattedString = this.toRgbString();
190
- }
191
- if (format === "prgb") {
192
- formattedString = this.toPercentageRgbString();
193
- }
194
- if (format === "hex" || format === "hex6") {
195
- formattedString = this.toHexString();
196
- }
197
- if (format === "hex3") {
198
- formattedString = this.toHexString(true);
199
- }
200
- if (format === "hex4") {
201
- formattedString = this.toHex8String(true);
202
- }
203
- if (format === "hex8") {
204
- formattedString = this.toHex8String();
205
- }
206
- if (format === "name") {
207
- formattedString = this.toName();
208
- }
209
- if (format === "hsl") {
210
- formattedString = this.toHslString();
211
- }
212
- if (format === "hsv") {
213
- formattedString = this.toHsvString();
214
- }
215
- return formattedString || this.toHexString();
216
- },
217
- clone: function clone() {
218
- return tinycolor(this.toString());
219
- },
220
- _applyModification: function _applyModification(fn, args) {
221
- var color = fn.apply(null, [this].concat([].slice.call(args)));
222
- this._r = color._r;
223
- this._g = color._g;
224
- this._b = color._b;
225
- this.setAlpha(color._a);
226
- return this;
227
- },
228
- lighten: function lighten() {
229
- return this._applyModification(_lighten, arguments);
230
- },
231
- brighten: function brighten() {
232
- return this._applyModification(_brighten, arguments);
233
- },
234
- darken: function darken() {
235
- return this._applyModification(_darken, arguments);
236
- },
237
- desaturate: function desaturate() {
238
- return this._applyModification(_desaturate, arguments);
239
- },
240
- saturate: function saturate() {
241
- return this._applyModification(_saturate, arguments);
242
- },
243
- greyscale: function greyscale() {
244
- return this._applyModification(_greyscale, arguments);
245
- },
246
- spin: function spin() {
247
- return this._applyModification(_spin, arguments);
248
- },
249
- _applyCombination: function _applyCombination(fn, args) {
250
- return fn.apply(null, [this].concat([].slice.call(args)));
251
- },
252
- analogous: function analogous() {
253
- return this._applyCombination(_analogous, arguments);
254
- },
255
- complement: function complement() {
256
- return this._applyCombination(_complement, arguments);
257
- },
258
- monochromatic: function monochromatic() {
259
- return this._applyCombination(_monochromatic, arguments);
260
- },
261
- splitcomplement: function splitcomplement() {
262
- return this._applyCombination(_splitcomplement, arguments);
263
- },
264
- // Disabled until https://github.com/bgrins/TinyColor/issues/254
265
- // polyad: function (number) {
266
- // return this._applyCombination(polyad, [number]);
267
- // },
268
- triad: function triad() {
269
- return this._applyCombination(polyad, [3]);
270
- },
271
- tetrad: function tetrad() {
272
- return this._applyCombination(polyad, [4]);
273
- }
274
- };
275
-
276
- // If input is an object, force 1 into "1.0" to handle ratios properly
277
- // String input requires "1.0" as input, so 1 will be treated as 1
278
- tinycolor.fromRatio = function (color, opts) {
279
- if (_typeof(color) == "object") {
280
- var newColor = {};
281
- for (var i in color) {
282
- if (color.hasOwnProperty(i)) {
283
- if (i === "a") {
284
- newColor[i] = color[i];
285
- } else {
286
- newColor[i] = convertToPercentage(color[i]);
287
- }
288
- }
289
- }
290
- color = newColor;
291
- }
292
- return tinycolor(color, opts);
293
- };
294
-
295
- // Given a string or object, convert that input to RGB
296
- // Possible string inputs:
297
- //
298
- // "red"
299
- // "#f00" or "f00"
300
- // "#ff0000" or "ff0000"
301
- // "#ff000000" or "ff000000"
302
- // "rgb 255 0 0" or "rgb (255, 0, 0)"
303
- // "rgb 1.0 0 0" or "rgb (1, 0, 0)"
304
- // "rgba (255, 0, 0, 1)" or "rgba 255, 0, 0, 1"
305
- // "rgba (1.0, 0, 0, 1)" or "rgba 1.0, 0, 0, 1"
306
- // "hsl(0, 100%, 50%)" or "hsl 0 100% 50%"
307
- // "hsla(0, 100%, 50%, 1)" or "hsla 0 100% 50%, 1"
308
- // "hsv(0, 100%, 100%)" or "hsv 0 100% 100%"
309
- //
310
- function inputToRGB(color) {
311
- var rgb = {
312
- r: 0,
313
- g: 0,
314
- b: 0
315
- };
316
- var a = 1;
317
- var s = null;
318
- var v = null;
319
- var l = null;
320
- var ok = false;
321
- var format = false;
322
- if (typeof color == "string") {
323
- color = stringInputToObject(color);
324
- }
325
- if (_typeof(color) == "object") {
326
- if (isValidCSSUnit(color.r) && isValidCSSUnit(color.g) && isValidCSSUnit(color.b)) {
327
- rgb = rgbToRgb(color.r, color.g, color.b);
328
- ok = true;
329
- format = String(color.r).substr(-1) === "%" ? "prgb" : "rgb";
330
- } else if (isValidCSSUnit(color.h) && isValidCSSUnit(color.s) && isValidCSSUnit(color.v)) {
331
- s = convertToPercentage(color.s);
332
- v = convertToPercentage(color.v);
333
- rgb = hsvToRgb(color.h, s, v);
334
- ok = true;
335
- format = "hsv";
336
- } else if (isValidCSSUnit(color.h) && isValidCSSUnit(color.s) && isValidCSSUnit(color.l)) {
337
- s = convertToPercentage(color.s);
338
- l = convertToPercentage(color.l);
339
- rgb = hslToRgb(color.h, s, l);
340
- ok = true;
341
- format = "hsl";
342
- }
343
- if (color.hasOwnProperty("a")) {
344
- a = color.a;
345
- }
346
- }
347
- a = boundAlpha(a);
348
- return {
349
- ok: ok,
350
- format: color.format || format,
351
- r: Math.min(255, Math.max(rgb.r, 0)),
352
- g: Math.min(255, Math.max(rgb.g, 0)),
353
- b: Math.min(255, Math.max(rgb.b, 0)),
354
- a: a
355
- };
356
- }
357
-
358
- // Conversion Functions
359
- // --------------------
360
-
361
- // `rgbToHsl`, `rgbToHsv`, `hslToRgb`, `hsvToRgb` modified from:
362
- // <http://mjijackson.com/2008/02/rgb-to-hsl-and-rgb-to-hsv-color-model-conversion-algorithms-in-javascript>
363
-
364
- // `rgbToRgb`
365
- // Handle bounds / percentage checking to conform to CSS color spec
366
- // <http://www.w3.org/TR/css3-color/>
367
- // *Assumes:* r, g, b in [0, 255] or [0, 1]
368
- // *Returns:* { r, g, b } in [0, 255]
369
- function rgbToRgb(r, g, b) {
370
- return {
371
- r: bound01(r, 255) * 255,
372
- g: bound01(g, 255) * 255,
373
- b: bound01(b, 255) * 255
374
- };
375
- }
376
-
377
- // `rgbToHsl`
378
- // Converts an RGB color value to HSL.
379
- // *Assumes:* r, g, and b are contained in [0, 255] or [0, 1]
380
- // *Returns:* { h, s, l } in [0,1]
381
- function rgbToHsl(r, g, b) {
382
- r = bound01(r, 255);
383
- g = bound01(g, 255);
384
- b = bound01(b, 255);
385
- var max = Math.max(r, g, b),
386
- min = Math.min(r, g, b);
387
- var h,
388
- s,
389
- l = (max + min) / 2;
390
- if (max == min) {
391
- h = s = 0; // achromatic
392
- } else {
393
- var d = max - min;
394
- s = l > 0.5 ? d / (2 - max - min) : d / (max + min);
395
- switch (max) {
396
- case r:
397
- h = (g - b) / d + (g < b ? 6 : 0);
398
- break;
399
- case g:
400
- h = (b - r) / d + 2;
401
- break;
402
- case b:
403
- h = (r - g) / d + 4;
404
- break;
405
- }
406
- h /= 6;
407
- }
408
- return {
409
- h: h,
410
- s: s,
411
- l: l
412
- };
413
- }
414
-
415
- // `hslToRgb`
416
- // Converts an HSL color value to RGB.
417
- // *Assumes:* h is contained in [0, 1] or [0, 360] and s and l are contained [0, 1] or [0, 100]
418
- // *Returns:* { r, g, b } in the set [0, 255]
419
- function hslToRgb(h, s, l) {
420
- var r, g, b;
421
- h = bound01(h, 360);
422
- s = bound01(s, 100);
423
- l = bound01(l, 100);
424
- function hue2rgb(p, q, t) {
425
- if (t < 0) t += 1;
426
- if (t > 1) t -= 1;
427
- if (t < 1 / 6) return p + (q - p) * 6 * t;
428
- if (t < 1 / 2) return q;
429
- if (t < 2 / 3) return p + (q - p) * (2 / 3 - t) * 6;
430
- return p;
431
- }
432
- if (s === 0) {
433
- r = g = b = l; // achromatic
434
- } else {
435
- var q = l < 0.5 ? l * (1 + s) : l + s - l * s;
436
- var p = 2 * l - q;
437
- r = hue2rgb(p, q, h + 1 / 3);
438
- g = hue2rgb(p, q, h);
439
- b = hue2rgb(p, q, h - 1 / 3);
440
- }
441
- return {
442
- r: r * 255,
443
- g: g * 255,
444
- b: b * 255
445
- };
446
- }
447
-
448
- // `rgbToHsv`
449
- // Converts an RGB color value to HSV
450
- // *Assumes:* r, g, and b are contained in the set [0, 255] or [0, 1]
451
- // *Returns:* { h, s, v } in [0,1]
452
- function rgbToHsv(r, g, b) {
453
- r = bound01(r, 255);
454
- g = bound01(g, 255);
455
- b = bound01(b, 255);
456
- var max = Math.max(r, g, b),
457
- min = Math.min(r, g, b);
458
- var h,
459
- s,
460
- v = max;
461
- var d = max - min;
462
- s = max === 0 ? 0 : d / max;
463
- if (max == min) {
464
- h = 0; // achromatic
465
- } else {
466
- switch (max) {
467
- case r:
468
- h = (g - b) / d + (g < b ? 6 : 0);
469
- break;
470
- case g:
471
- h = (b - r) / d + 2;
472
- break;
473
- case b:
474
- h = (r - g) / d + 4;
475
- break;
476
- }
477
- h /= 6;
478
- }
479
- return {
480
- h: h,
481
- s: s,
482
- v: v
483
- };
484
- }
485
-
486
- // `hsvToRgb`
487
- // Converts an HSV color value to RGB.
488
- // *Assumes:* h is contained in [0, 1] or [0, 360] and s and v are contained in [0, 1] or [0, 100]
489
- // *Returns:* { r, g, b } in the set [0, 255]
490
- function hsvToRgb(h, s, v) {
491
- h = bound01(h, 360) * 6;
492
- s = bound01(s, 100);
493
- v = bound01(v, 100);
494
- var i = Math.floor(h),
495
- f = h - i,
496
- p = v * (1 - s),
497
- q = v * (1 - f * s),
498
- t = v * (1 - (1 - f) * s),
499
- mod = i % 6,
500
- r = [v, q, p, p, t, v][mod],
501
- g = [t, v, v, q, p, p][mod],
502
- b = [p, p, t, v, v, q][mod];
503
- return {
504
- r: r * 255,
505
- g: g * 255,
506
- b: b * 255
507
- };
508
- }
509
-
510
- // `rgbToHex`
511
- // Converts an RGB color to hex
512
- // Assumes r, g, and b are contained in the set [0, 255]
513
- // Returns a 3 or 6 character hex
514
- function rgbToHex(r, g, b, allow3Char) {
515
- var hex = [pad2(Math.round(r).toString(16)), pad2(Math.round(g).toString(16)), pad2(Math.round(b).toString(16))];
516
-
517
- // Return a 3 character hex if possible
518
- if (allow3Char && hex[0].charAt(0) == hex[0].charAt(1) && hex[1].charAt(0) == hex[1].charAt(1) && hex[2].charAt(0) == hex[2].charAt(1)) {
519
- return hex[0].charAt(0) + hex[1].charAt(0) + hex[2].charAt(0);
520
- }
521
- return hex.join("");
522
- }
523
-
524
- // `rgbaToHex`
525
- // Converts an RGBA color plus alpha transparency to hex
526
- // Assumes r, g, b are contained in the set [0, 255] and
527
- // a in [0, 1]. Returns a 4 or 8 character rgba hex
528
- function rgbaToHex(r, g, b, a, allow4Char) {
529
- var hex = [pad2(Math.round(r).toString(16)), pad2(Math.round(g).toString(16)), pad2(Math.round(b).toString(16)), pad2(convertDecimalToHex(a))];
530
-
531
- // Return a 4 character hex if possible
532
- if (allow4Char && hex[0].charAt(0) == hex[0].charAt(1) && hex[1].charAt(0) == hex[1].charAt(1) && hex[2].charAt(0) == hex[2].charAt(1) && hex[3].charAt(0) == hex[3].charAt(1)) {
533
- return hex[0].charAt(0) + hex[1].charAt(0) + hex[2].charAt(0) + hex[3].charAt(0);
534
- }
535
- return hex.join("");
536
- }
537
-
538
- // `rgbaToArgbHex`
539
- // Converts an RGBA color to an ARGB Hex8 string
540
- // Rarely used, but required for "toFilter()"
541
- function rgbaToArgbHex(r, g, b, a) {
542
- var hex = [pad2(convertDecimalToHex(a)), pad2(Math.round(r).toString(16)), pad2(Math.round(g).toString(16)), pad2(Math.round(b).toString(16))];
543
- return hex.join("");
544
- }
545
-
546
- // `equals`
547
- // Can be called with any tinycolor input
548
- tinycolor.equals = function (color1, color2) {
549
- if (!color1 || !color2) return false;
550
- return tinycolor(color1).toRgbString() == tinycolor(color2).toRgbString();
551
- };
552
- tinycolor.random = function () {
553
- return tinycolor.fromRatio({
554
- r: Math.random(),
555
- g: Math.random(),
556
- b: Math.random()
557
- });
558
- };
559
-
560
- // Modification Functions
561
- // ----------------------
562
- // Thanks to less.js for some of the basics here
563
- // <https://github.com/cloudhead/less.js/blob/master/lib/less/functions.js>
564
-
565
- function _desaturate(color, amount) {
566
- amount = amount === 0 ? 0 : amount || 10;
567
- var hsl = tinycolor(color).toHsl();
568
- hsl.s -= amount / 100;
569
- hsl.s = clamp01(hsl.s);
570
- return tinycolor(hsl);
571
- }
572
- function _saturate(color, amount) {
573
- amount = amount === 0 ? 0 : amount || 10;
574
- var hsl = tinycolor(color).toHsl();
575
- hsl.s += amount / 100;
576
- hsl.s = clamp01(hsl.s);
577
- return tinycolor(hsl);
578
- }
579
- function _greyscale(color) {
580
- return tinycolor(color).desaturate(100);
581
- }
582
- function _lighten(color, amount) {
583
- amount = amount === 0 ? 0 : amount || 10;
584
- var hsl = tinycolor(color).toHsl();
585
- hsl.l += amount / 100;
586
- hsl.l = clamp01(hsl.l);
587
- return tinycolor(hsl);
588
- }
589
- function _brighten(color, amount) {
590
- amount = amount === 0 ? 0 : amount || 10;
591
- var rgb = tinycolor(color).toRgb();
592
- rgb.r = Math.max(0, Math.min(255, rgb.r - Math.round(255 * -(amount / 100))));
593
- rgb.g = Math.max(0, Math.min(255, rgb.g - Math.round(255 * -(amount / 100))));
594
- rgb.b = Math.max(0, Math.min(255, rgb.b - Math.round(255 * -(amount / 100))));
595
- return tinycolor(rgb);
596
- }
597
- function _darken(color, amount) {
598
- amount = amount === 0 ? 0 : amount || 10;
599
- var hsl = tinycolor(color).toHsl();
600
- hsl.l -= amount / 100;
601
- hsl.l = clamp01(hsl.l);
602
- return tinycolor(hsl);
603
- }
604
-
605
- // Spin takes a positive or negative amount within [-360, 360] indicating the change of hue.
606
- // Values outside of this range will be wrapped into this range.
607
- function _spin(color, amount) {
608
- var hsl = tinycolor(color).toHsl();
609
- var hue = (hsl.h + amount) % 360;
610
- hsl.h = hue < 0 ? 360 + hue : hue;
611
- return tinycolor(hsl);
612
- }
613
-
614
- // Combination Functions
615
- // ---------------------
616
- // Thanks to jQuery xColor for some of the ideas behind these
617
- // <https://github.com/infusion/jQuery-xcolor/blob/master/jquery.xcolor.js>
618
-
619
- function _complement(color) {
620
- var hsl = tinycolor(color).toHsl();
621
- hsl.h = (hsl.h + 180) % 360;
622
- return tinycolor(hsl);
623
- }
624
- function polyad(color, number) {
625
- if (isNaN(number) || number <= 0) {
626
- throw new Error("Argument to polyad must be a positive number");
627
- }
628
- var hsl = tinycolor(color).toHsl();
629
- var result = [tinycolor(color)];
630
- var step = 360 / number;
631
- for (var i = 1; i < number; i++) {
632
- result.push(tinycolor({
633
- h: (hsl.h + i * step) % 360,
634
- s: hsl.s,
635
- l: hsl.l
636
- }));
637
- }
638
- return result;
639
- }
640
- function _splitcomplement(color) {
641
- var hsl = tinycolor(color).toHsl();
642
- var h = hsl.h;
643
- return [tinycolor(color), tinycolor({
644
- h: (h + 72) % 360,
645
- s: hsl.s,
646
- l: hsl.l
647
- }), tinycolor({
648
- h: (h + 216) % 360,
649
- s: hsl.s,
650
- l: hsl.l
651
- })];
652
- }
653
- function _analogous(color, results, slices) {
654
- results = results || 6;
655
- slices = slices || 30;
656
- var hsl = tinycolor(color).toHsl();
657
- var part = 360 / slices;
658
- var ret = [tinycolor(color)];
659
- for (hsl.h = (hsl.h - (part * results >> 1) + 720) % 360; --results;) {
660
- hsl.h = (hsl.h + part) % 360;
661
- ret.push(tinycolor(hsl));
662
- }
663
- return ret;
664
- }
665
- function _monochromatic(color, results) {
666
- results = results || 6;
667
- var hsv = tinycolor(color).toHsv();
668
- var h = hsv.h,
669
- s = hsv.s,
670
- v = hsv.v;
671
- var ret = [];
672
- var modification = 1 / results;
673
- while (results--) {
674
- ret.push(tinycolor({
675
- h: h,
676
- s: s,
677
- v: v
678
- }));
679
- v = (v + modification) % 1;
680
- }
681
- return ret;
682
- }
683
-
684
- // Utility Functions
685
- // ---------------------
686
-
687
- tinycolor.mix = function (color1, color2, amount) {
688
- amount = amount === 0 ? 0 : amount || 50;
689
- var rgb1 = tinycolor(color1).toRgb();
690
- var rgb2 = tinycolor(color2).toRgb();
691
- var p = amount / 100;
692
- var rgba = {
693
- r: (rgb2.r - rgb1.r) * p + rgb1.r,
694
- g: (rgb2.g - rgb1.g) * p + rgb1.g,
695
- b: (rgb2.b - rgb1.b) * p + rgb1.b,
696
- a: (rgb2.a - rgb1.a) * p + rgb1.a
697
- };
698
- return tinycolor(rgba);
699
- };
700
-
701
- // Readability Functions
702
- // ---------------------
703
- // <http://www.w3.org/TR/2008/REC-WCAG20-20081211/#contrast-ratiodef (WCAG Version 2)
704
-
705
- // `contrast`
706
- // Analyze the 2 colors and returns the color contrast defined by (WCAG Version 2)
707
- tinycolor.readability = function (color1, color2) {
708
- var c1 = tinycolor(color1);
709
- var c2 = tinycolor(color2);
710
- return (Math.max(c1.getLuminance(), c2.getLuminance()) + 0.05) / (Math.min(c1.getLuminance(), c2.getLuminance()) + 0.05);
711
- };
712
-
713
- // `isReadable`
714
- // Ensure that foreground and background color combinations meet WCAG2 guidelines.
715
- // The third argument is an optional Object.
716
- // the 'level' property states 'AA' or 'AAA' - if missing or invalid, it defaults to 'AA';
717
- // the 'size' property states 'large' or 'small' - if missing or invalid, it defaults to 'small'.
718
- // If the entire object is absent, isReadable defaults to {level:"AA",size:"small"}.
719
-
720
- // *Example*
721
- // tinycolor.isReadable("#000", "#111") => false
722
- // tinycolor.isReadable("#000", "#111",{level:"AA",size:"large"}) => false
723
- tinycolor.isReadable = function (color1, color2, wcag2) {
724
- var readability = tinycolor.readability(color1, color2);
725
- var wcag2Parms, out;
726
- out = false;
727
- wcag2Parms = validateWCAG2Parms(wcag2);
728
- switch (wcag2Parms.level + wcag2Parms.size) {
729
- case "AAsmall":
730
- case "AAAlarge":
731
- out = readability >= 4.5;
732
- break;
733
- case "AAlarge":
734
- out = readability >= 3;
735
- break;
736
- case "AAAsmall":
737
- out = readability >= 7;
738
- break;
739
- }
740
- return out;
741
- };
742
-
743
- // `mostReadable`
744
- // Given a base color and a list of possible foreground or background
745
- // colors for that base, returns the most readable color.
746
- // Optionally returns Black or White if the most readable color is unreadable.
747
- // *Example*
748
- // tinycolor.mostReadable(tinycolor.mostReadable("#123", ["#124", "#125"],{includeFallbackColors:false}).toHexString(); // "#112255"
749
- // tinycolor.mostReadable(tinycolor.mostReadable("#123", ["#124", "#125"],{includeFallbackColors:true}).toHexString(); // "#ffffff"
750
- // tinycolor.mostReadable("#a8015a", ["#faf3f3"],{includeFallbackColors:true,level:"AAA",size:"large"}).toHexString(); // "#faf3f3"
751
- // tinycolor.mostReadable("#a8015a", ["#faf3f3"],{includeFallbackColors:true,level:"AAA",size:"small"}).toHexString(); // "#ffffff"
752
- tinycolor.mostReadable = function (baseColor, colorList, args) {
753
- var bestColor = null;
754
- var bestScore = 0;
755
- var readability;
756
- var includeFallbackColors, level, size;
757
- args = args || {};
758
- includeFallbackColors = args.includeFallbackColors;
759
- level = args.level;
760
- size = args.size;
761
- for (var i = 0; i < colorList.length; i++) {
762
- readability = tinycolor.readability(baseColor, colorList[i]);
763
- if (readability > bestScore) {
764
- bestScore = readability;
765
- bestColor = tinycolor(colorList[i]);
766
- }
767
- }
768
- if (tinycolor.isReadable(baseColor, bestColor, {
769
- level: level,
770
- size: size
771
- }) || !includeFallbackColors) {
772
- return bestColor;
773
- } else {
774
- args.includeFallbackColors = false;
775
- return tinycolor.mostReadable(baseColor, ["#fff", "#000"], args);
776
- }
777
- };
778
-
779
- // Big List of Colors
780
- // ------------------
781
- // <https://www.w3.org/TR/css-color-4/#named-colors>
782
- var names = tinycolor.names = {
783
- aliceblue: "f0f8ff",
784
- antiquewhite: "faebd7",
785
- aqua: "0ff",
786
- aquamarine: "7fffd4",
787
- azure: "f0ffff",
788
- beige: "f5f5dc",
789
- bisque: "ffe4c4",
790
- black: "000",
791
- blanchedalmond: "ffebcd",
792
- blue: "00f",
793
- blueviolet: "8a2be2",
794
- brown: "a52a2a",
795
- burlywood: "deb887",
796
- burntsienna: "ea7e5d",
797
- cadetblue: "5f9ea0",
798
- chartreuse: "7fff00",
799
- chocolate: "d2691e",
800
- coral: "ff7f50",
801
- cornflowerblue: "6495ed",
802
- cornsilk: "fff8dc",
803
- crimson: "dc143c",
804
- cyan: "0ff",
805
- darkblue: "00008b",
806
- darkcyan: "008b8b",
807
- darkgoldenrod: "b8860b",
808
- darkgray: "a9a9a9",
809
- darkgreen: "006400",
810
- darkgrey: "a9a9a9",
811
- darkkhaki: "bdb76b",
812
- darkmagenta: "8b008b",
813
- darkolivegreen: "556b2f",
814
- darkorange: "ff8c00",
815
- darkorchid: "9932cc",
816
- darkred: "8b0000",
817
- darksalmon: "e9967a",
818
- darkseagreen: "8fbc8f",
819
- darkslateblue: "483d8b",
820
- darkslategray: "2f4f4f",
821
- darkslategrey: "2f4f4f",
822
- darkturquoise: "00ced1",
823
- darkviolet: "9400d3",
824
- deeppink: "ff1493",
825
- deepskyblue: "00bfff",
826
- dimgray: "696969",
827
- dimgrey: "696969",
828
- dodgerblue: "1e90ff",
829
- firebrick: "b22222",
830
- floralwhite: "fffaf0",
831
- forestgreen: "228b22",
832
- fuchsia: "f0f",
833
- gainsboro: "dcdcdc",
834
- ghostwhite: "f8f8ff",
835
- gold: "ffd700",
836
- goldenrod: "daa520",
837
- gray: "808080",
838
- green: "008000",
839
- greenyellow: "adff2f",
840
- grey: "808080",
841
- honeydew: "f0fff0",
842
- hotpink: "ff69b4",
843
- indianred: "cd5c5c",
844
- indigo: "4b0082",
845
- ivory: "fffff0",
846
- khaki: "f0e68c",
847
- lavender: "e6e6fa",
848
- lavenderblush: "fff0f5",
849
- lawngreen: "7cfc00",
850
- lemonchiffon: "fffacd",
851
- lightblue: "add8e6",
852
- lightcoral: "f08080",
853
- lightcyan: "e0ffff",
854
- lightgoldenrodyellow: "fafad2",
855
- lightgray: "d3d3d3",
856
- lightgreen: "90ee90",
857
- lightgrey: "d3d3d3",
858
- lightpink: "ffb6c1",
859
- lightsalmon: "ffa07a",
860
- lightseagreen: "20b2aa",
861
- lightskyblue: "87cefa",
862
- lightslategray: "789",
863
- lightslategrey: "789",
864
- lightsteelblue: "b0c4de",
865
- lightyellow: "ffffe0",
866
- lime: "0f0",
867
- limegreen: "32cd32",
868
- linen: "faf0e6",
869
- magenta: "f0f",
870
- maroon: "800000",
871
- mediumaquamarine: "66cdaa",
872
- mediumblue: "0000cd",
873
- mediumorchid: "ba55d3",
874
- mediumpurple: "9370db",
875
- mediumseagreen: "3cb371",
876
- mediumslateblue: "7b68ee",
877
- mediumspringgreen: "00fa9a",
878
- mediumturquoise: "48d1cc",
879
- mediumvioletred: "c71585",
880
- midnightblue: "191970",
881
- mintcream: "f5fffa",
882
- mistyrose: "ffe4e1",
883
- moccasin: "ffe4b5",
884
- navajowhite: "ffdead",
885
- navy: "000080",
886
- oldlace: "fdf5e6",
887
- olive: "808000",
888
- olivedrab: "6b8e23",
889
- orange: "ffa500",
890
- orangered: "ff4500",
891
- orchid: "da70d6",
892
- palegoldenrod: "eee8aa",
893
- palegreen: "98fb98",
894
- paleturquoise: "afeeee",
895
- palevioletred: "db7093",
896
- papayawhip: "ffefd5",
897
- peachpuff: "ffdab9",
898
- peru: "cd853f",
899
- pink: "ffc0cb",
900
- plum: "dda0dd",
901
- powderblue: "b0e0e6",
902
- purple: "800080",
903
- rebeccapurple: "663399",
904
- red: "f00",
905
- rosybrown: "bc8f8f",
906
- royalblue: "4169e1",
907
- saddlebrown: "8b4513",
908
- salmon: "fa8072",
909
- sandybrown: "f4a460",
910
- seagreen: "2e8b57",
911
- seashell: "fff5ee",
912
- sienna: "a0522d",
913
- silver: "c0c0c0",
914
- skyblue: "87ceeb",
915
- slateblue: "6a5acd",
916
- slategray: "708090",
917
- slategrey: "708090",
918
- snow: "fffafa",
919
- springgreen: "00ff7f",
920
- steelblue: "4682b4",
921
- tan: "d2b48c",
922
- teal: "008080",
923
- thistle: "d8bfd8",
924
- tomato: "ff6347",
925
- turquoise: "40e0d0",
926
- violet: "ee82ee",
927
- wheat: "f5deb3",
928
- white: "fff",
929
- whitesmoke: "f5f5f5",
930
- yellow: "ff0",
931
- yellowgreen: "9acd32"
932
- };
933
-
934
- // Make it easy to access colors via `hexNames[hex]`
935
- var hexNames = tinycolor.hexNames = flip(names);
936
-
937
- // Utilities
938
- // ---------
939
-
940
- // `{ 'name1': 'val1' }` becomes `{ 'val1': 'name1' }`
941
- function flip(o) {
942
- var flipped = {};
943
- for (var i in o) {
944
- if (o.hasOwnProperty(i)) {
945
- flipped[o[i]] = i;
946
- }
947
- }
948
- return flipped;
949
- }
950
-
951
- // Return a valid alpha value [0,1] with all invalid values being set to 1
952
- function boundAlpha(a) {
953
- a = parseFloat(a);
954
- if (isNaN(a) || a < 0 || a > 1) {
955
- a = 1;
956
- }
957
- return a;
958
- }
959
-
960
- // Take input from [0, n] and return it as [0, 1]
961
- function bound01(n, max) {
962
- if (isOnePointZero(n)) n = "100%";
963
- var processPercent = isPercentage(n);
964
- n = Math.min(max, Math.max(0, parseFloat(n)));
965
-
966
- // Automatically convert percentage into number
967
- if (processPercent) {
968
- n = parseInt(n * max, 10) / 100;
969
- }
970
-
971
- // Handle floating point rounding errors
972
- if (Math.abs(n - max) < 0.000001) {
973
- return 1;
974
- }
975
-
976
- // Convert into [0, 1] range if it isn't already
977
- return n % max / parseFloat(max);
978
- }
979
-
980
- // Force a number between 0 and 1
981
- function clamp01(val) {
982
- return Math.min(1, Math.max(0, val));
983
- }
984
-
985
- // Parse a base-16 hex value into a base-10 integer
986
- function parseIntFromHex(val) {
987
- return parseInt(val, 16);
988
- }
989
-
990
- // Need to handle 1.0 as 100%, since once it is a number, there is no difference between it and 1
991
- // <http://stackoverflow.com/questions/7422072/javascript-how-to-detect-number-as-a-decimal-including-1-0>
992
- function isOnePointZero(n) {
993
- return typeof n == "string" && n.indexOf(".") != -1 && parseFloat(n) === 1;
994
- }
995
-
996
- // Check to see if string passed in is a percentage
997
- function isPercentage(n) {
998
- return typeof n === "string" && n.indexOf("%") != -1;
999
- }
1000
-
1001
- // Force a hex value to have 2 characters
1002
- function pad2(c) {
1003
- return c.length == 1 ? "0" + c : "" + c;
1004
- }
1005
-
1006
- // Replace a decimal with it's percentage value
1007
- function convertToPercentage(n) {
1008
- if (n <= 1) {
1009
- n = n * 100 + "%";
1010
- }
1011
- return n;
1012
- }
1013
-
1014
- // Converts a decimal to a hex value
1015
- function convertDecimalToHex(d) {
1016
- return Math.round(parseFloat(d) * 255).toString(16);
1017
- }
1018
- // Converts a hex value to a decimal
1019
- function convertHexToDecimal(h) {
1020
- return parseIntFromHex(h) / 255;
1021
- }
1022
- var matchers = function () {
1023
- // <http://www.w3.org/TR/css3-values/#integers>
1024
- var CSS_INTEGER = "[-\\+]?\\d+%?";
1025
-
1026
- // <http://www.w3.org/TR/css3-values/#number-value>
1027
- var CSS_NUMBER = "[-\\+]?\\d*\\.\\d+%?";
1028
-
1029
- // Allow positive/negative integer/number. Don't capture the either/or, just the entire outcome.
1030
- var CSS_UNIT = "(?:" + CSS_NUMBER + ")|(?:" + CSS_INTEGER + ")";
1031
-
1032
- // Actual matching.
1033
- // Parentheses and commas are optional, but not required.
1034
- // Whitespace can take the place of commas or opening paren
1035
- var PERMISSIVE_MATCH3 = "[\\s|\\(]+(" + CSS_UNIT + ")[,|\\s]+(" + CSS_UNIT + ")[,|\\s]+(" + CSS_UNIT + ")\\s*\\)?";
1036
- var PERMISSIVE_MATCH4 = "[\\s|\\(]+(" + CSS_UNIT + ")[,|\\s]+(" + CSS_UNIT + ")[,|\\s]+(" + CSS_UNIT + ")[,|\\s]+(" + CSS_UNIT + ")\\s*\\)?";
1037
- return {
1038
- CSS_UNIT: new RegExp(CSS_UNIT),
1039
- rgb: new RegExp("rgb" + PERMISSIVE_MATCH3),
1040
- rgba: new RegExp("rgba" + PERMISSIVE_MATCH4),
1041
- hsl: new RegExp("hsl" + PERMISSIVE_MATCH3),
1042
- hsla: new RegExp("hsla" + PERMISSIVE_MATCH4),
1043
- hsv: new RegExp("hsv" + PERMISSIVE_MATCH3),
1044
- hsva: new RegExp("hsva" + PERMISSIVE_MATCH4),
1045
- hex3: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,
1046
- hex6: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,
1047
- hex4: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,
1048
- hex8: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/
1049
- };
1050
- }();
1051
-
1052
- // `isValidCSSUnit`
1053
- // Take in a single string / number and check to see if it looks like a CSS unit
1054
- // (see `matchers` above for definition).
1055
- function isValidCSSUnit(color) {
1056
- return !!matchers.CSS_UNIT.exec(color);
1057
- }
1058
-
1059
- // `stringInputToObject`
1060
- // Permissive string parsing. Take in a number of formats, and output an object
1061
- // based on detected format. Returns `{ r, g, b }` or `{ h, s, l }` or `{ h, s, v}`
1062
- function stringInputToObject(color) {
1063
- color = color.replace(trimLeft, "").replace(trimRight, "").toLowerCase();
1064
- var named = false;
1065
- if (names[color]) {
1066
- color = names[color];
1067
- named = true;
1068
- } else if (color == "transparent") {
1069
- return {
1070
- r: 0,
1071
- g: 0,
1072
- b: 0,
1073
- a: 0,
1074
- format: "name"
1075
- };
1076
- }
1077
-
1078
- // Try to match string input using regular expressions.
1079
- // Keep most of the number bounding out of this function - don't worry about [0,1] or [0,100] or [0,360]
1080
- // Just return an object and let the conversion functions handle that.
1081
- // This way the result will be the same whether the tinycolor is initialized with string or object.
1082
- var match;
1083
- if (match = matchers.rgb.exec(color)) {
1084
- return {
1085
- r: match[1],
1086
- g: match[2],
1087
- b: match[3]
1088
- };
1089
- }
1090
- if (match = matchers.rgba.exec(color)) {
1091
- return {
1092
- r: match[1],
1093
- g: match[2],
1094
- b: match[3],
1095
- a: match[4]
1096
- };
1097
- }
1098
- if (match = matchers.hsl.exec(color)) {
1099
- return {
1100
- h: match[1],
1101
- s: match[2],
1102
- l: match[3]
1103
- };
1104
- }
1105
- if (match = matchers.hsla.exec(color)) {
1106
- return {
1107
- h: match[1],
1108
- s: match[2],
1109
- l: match[3],
1110
- a: match[4]
1111
- };
1112
- }
1113
- if (match = matchers.hsv.exec(color)) {
1114
- return {
1115
- h: match[1],
1116
- s: match[2],
1117
- v: match[3]
1118
- };
1119
- }
1120
- if (match = matchers.hsva.exec(color)) {
1121
- return {
1122
- h: match[1],
1123
- s: match[2],
1124
- v: match[3],
1125
- a: match[4]
1126
- };
1127
- }
1128
- if (match = matchers.hex8.exec(color)) {
1129
- return {
1130
- r: parseIntFromHex(match[1]),
1131
- g: parseIntFromHex(match[2]),
1132
- b: parseIntFromHex(match[3]),
1133
- a: convertHexToDecimal(match[4]),
1134
- format: named ? "name" : "hex8"
1135
- };
1136
- }
1137
- if (match = matchers.hex6.exec(color)) {
1138
- return {
1139
- r: parseIntFromHex(match[1]),
1140
- g: parseIntFromHex(match[2]),
1141
- b: parseIntFromHex(match[3]),
1142
- format: named ? "name" : "hex"
1143
- };
1144
- }
1145
- if (match = matchers.hex4.exec(color)) {
1146
- return {
1147
- r: parseIntFromHex(match[1] + "" + match[1]),
1148
- g: parseIntFromHex(match[2] + "" + match[2]),
1149
- b: parseIntFromHex(match[3] + "" + match[3]),
1150
- a: convertHexToDecimal(match[4] + "" + match[4]),
1151
- format: named ? "name" : "hex8"
1152
- };
1153
- }
1154
- if (match = matchers.hex3.exec(color)) {
1155
- return {
1156
- r: parseIntFromHex(match[1] + "" + match[1]),
1157
- g: parseIntFromHex(match[2] + "" + match[2]),
1158
- b: parseIntFromHex(match[3] + "" + match[3]),
1159
- format: named ? "name" : "hex"
1160
- };
1161
- }
1162
- return false;
1163
- }
1164
- function validateWCAG2Parms(parms) {
1165
- // return valid WCAG2 parms for isReadable.
1166
- // If input parms are invalid, return {"level":"AA", "size":"small"}
1167
- var level, size;
1168
- parms = parms || {
1169
- level: "AA",
1170
- size: "small"
1171
- };
1172
- level = (parms.level || "AA").toUpperCase();
1173
- size = (parms.size || "small").toLowerCase();
1174
- if (level !== "AA" && level !== "AAA") {
1175
- level = "AA";
1176
- }
1177
- if (size !== "small" && size !== "large") {
1178
- size = "small";
1179
- }
1180
- return {
1181
- level: level,
1182
- size: size
1183
- };
1184
- }
1185
-
1186
- return tinycolor;
1187
-
1188
- }));
1189
- });
1190
-
1191
- const isDarkColor = (color) => {
1192
- return tinycolor(color).isDark();
1193
- };
1194
-
1195
- export { isDarkColor as i };
1196
-
1197
- //# sourceMappingURL=isDarkColor-3bb345f4.js.map