@thecb/components 2.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (308) hide show
  1. package/.eslintrc.json +29 -0
  2. package/.github/PULL_REQUEST_TEMPLATE.md +18 -0
  3. package/.github/stale.yml +17 -0
  4. package/.prettierignore +3 -0
  5. package/.tool-versions +1 -0
  6. package/README.md +149 -0
  7. package/dist/cb-components.cjs.js +77 -0
  8. package/package.json +96 -0
  9. package/rollup.config.js +35 -0
  10. package/src/components/atoms/alert/Alert.js +67 -0
  11. package/src/components/atoms/alert/Alert.theme.js +71 -0
  12. package/src/components/atoms/alert/index.js +3 -0
  13. package/src/components/atoms/amount-callout/AmountCallout.js +27 -0
  14. package/src/components/atoms/amount-callout/AmountCallout.theme.js +19 -0
  15. package/src/components/atoms/amount-callout/index.js +3 -0
  16. package/src/components/atoms/breadcrumb/Breadcrumb.js +50 -0
  17. package/src/components/atoms/breadcrumb/Breadcrumb.theme.js +25 -0
  18. package/src/components/atoms/breadcrumb/index.js +3 -0
  19. package/src/components/atoms/button-with-action/ButtonWithAction.js +128 -0
  20. package/src/components/atoms/button-with-action/ButtonWithAction.stories.js +125 -0
  21. package/src/components/atoms/button-with-action/ButtonWithAction.theme.js +360 -0
  22. package/src/components/atoms/button-with-action/index.js +3 -0
  23. package/src/components/atoms/button-with-link/ButtonWithLink.js +40 -0
  24. package/src/components/atoms/button-with-link/index.js +3 -0
  25. package/src/components/atoms/checkbox/Checkbox.js +143 -0
  26. package/src/components/atoms/checkbox/Checkbox.theme.js +54 -0
  27. package/src/components/atoms/checkbox/index.js +3 -0
  28. package/src/components/atoms/checkbox-list/CheckboxList.js +129 -0
  29. package/src/components/atoms/checkbox-list/CheckboxList.theme.js +42 -0
  30. package/src/components/atoms/checkbox-list/index.js +3 -0
  31. package/src/components/atoms/country-dropdown/CountryDropdown.js +24 -0
  32. package/src/components/atoms/country-dropdown/index.js +1 -0
  33. package/src/components/atoms/country-dropdown/options.js +249 -0
  34. package/src/components/atoms/display-box/DisplayBox.js +22 -0
  35. package/src/components/atoms/display-box/DisplayBox.theme.js +9 -0
  36. package/src/components/atoms/display-box/index.js +3 -0
  37. package/src/components/atoms/display-card/DisplayCard.js +65 -0
  38. package/src/components/atoms/display-card/index.js +3 -0
  39. package/src/components/atoms/dropdown/Dropdown.js +299 -0
  40. package/src/components/atoms/dropdown/Dropdown.theme.js +9 -0
  41. package/src/components/atoms/dropdown/DropdownIcon.js +31 -0
  42. package/src/components/atoms/dropdown/index.js +3 -0
  43. package/src/components/atoms/form-layouts/FormContainer.js +28 -0
  44. package/src/components/atoms/form-layouts/FormInput.js +218 -0
  45. package/src/components/atoms/form-layouts/FormInputColumn.js +15 -0
  46. package/src/components/atoms/form-layouts/FormInputRow.js +26 -0
  47. package/src/components/atoms/form-layouts/FormLayouts.theme.js +52 -0
  48. package/src/components/atoms/form-layouts/index.js +6 -0
  49. package/src/components/atoms/form-select/FormSelect.js +62 -0
  50. package/src/components/atoms/form-select/FormSelect.styled.js +65 -0
  51. package/src/components/atoms/form-select/index.js +3 -0
  52. package/src/components/atoms/formatted-address/FormattedAddress.js +53 -0
  53. package/src/components/atoms/formatted-address/FormattedAddress.theme.js +11 -0
  54. package/src/components/atoms/formatted-address/index.js +3 -0
  55. package/src/components/atoms/hamburger-button/HamburgerButton.js +113 -0
  56. package/src/components/atoms/hamburger-button/index.js +3 -0
  57. package/src/components/atoms/heading/Heading.js +37 -0
  58. package/src/components/atoms/heading/Heading.styled.js +14 -0
  59. package/src/components/atoms/heading/Heading.theme.js +18 -0
  60. package/src/components/atoms/heading/index.js +3 -0
  61. package/src/components/atoms/icons/AccountsAddIcon.js +42 -0
  62. package/src/components/atoms/icons/AccountsIcon.js +37 -0
  63. package/src/components/atoms/icons/AccountsIconSmall.js +63 -0
  64. package/src/components/atoms/icons/ChevronIcon.js +51 -0
  65. package/src/components/atoms/icons/ForgotPasswordIcon.js +46 -0
  66. package/src/components/atoms/icons/GoToEmailIcon.js +31 -0
  67. package/src/components/atoms/icons/Icons.theme.js +38 -0
  68. package/src/components/atoms/icons/PaymentMethodIcon.js +42 -0
  69. package/src/components/atoms/icons/PaymentsIconSmall.js +63 -0
  70. package/src/components/atoms/icons/ProfileIconSmall.js +44 -0
  71. package/src/components/atoms/icons/PropertiesAddIcon.js +70 -0
  72. package/src/components/atoms/icons/PropertiesIconSmall.js +32 -0
  73. package/src/components/atoms/icons/SettingsIconSmall.js +63 -0
  74. package/src/components/atoms/icons/VerifiedEmailIcon.js +53 -0
  75. package/src/components/atoms/icons/index.js +28 -0
  76. package/src/components/atoms/index.js +33 -0
  77. package/src/components/atoms/labeled-amount/LabeledAmount.js +35 -0
  78. package/src/components/atoms/labeled-amount/LabeledAmount.theme.js +10 -0
  79. package/src/components/atoms/labeled-amount/index.js +3 -0
  80. package/src/components/atoms/layouts/Box.js +83 -0
  81. package/src/components/atoms/layouts/Box.styled.js +131 -0
  82. package/src/components/atoms/layouts/Center.js +28 -0
  83. package/src/components/atoms/layouts/Center.styled.js +18 -0
  84. package/src/components/atoms/layouts/Cluster.js +37 -0
  85. package/src/components/atoms/layouts/Cluster.styled.js +21 -0
  86. package/src/components/atoms/layouts/Cover.js +49 -0
  87. package/src/components/atoms/layouts/Cover.styled.js +29 -0
  88. package/src/components/atoms/layouts/Frame.js +28 -0
  89. package/src/components/atoms/layouts/Frame.styled.js +27 -0
  90. package/src/components/atoms/layouts/Grid.js +38 -0
  91. package/src/components/atoms/layouts/Grid.styled.js +22 -0
  92. package/src/components/atoms/layouts/Imposter.js +52 -0
  93. package/src/components/atoms/layouts/Imposter.styled.js +19 -0
  94. package/src/components/atoms/layouts/Motion.js +51 -0
  95. package/src/components/atoms/layouts/Motion.styled.js +41 -0
  96. package/src/components/atoms/layouts/Reel.js +28 -0
  97. package/src/components/atoms/layouts/Reel.styled.js +17 -0
  98. package/src/components/atoms/layouts/Sidebar.js +42 -0
  99. package/src/components/atoms/layouts/Sidebar.styled.js +38 -0
  100. package/src/components/atoms/layouts/Stack.js +36 -0
  101. package/src/components/atoms/layouts/Stack.styled.js +30 -0
  102. package/src/components/atoms/layouts/Switcher.js +64 -0
  103. package/src/components/atoms/layouts/Switcher.styled.js +44 -0
  104. package/src/components/atoms/layouts/examples/FixedSizeContainer.js +22 -0
  105. package/src/components/atoms/layouts/examples/FixedSizeContainer.styled.js +20 -0
  106. package/src/components/atoms/layouts/examples/LayoutContentBlock.js +27 -0
  107. package/src/components/atoms/layouts/examples/LayoutContentBlock.styled.js +15 -0
  108. package/src/components/atoms/layouts/examples/ResizingContainer.js +49 -0
  109. package/src/components/atoms/layouts/examples/ResizingContainer.styled.js +39 -0
  110. package/src/components/atoms/layouts/examples/cluster-example/ClusterExample.js +10 -0
  111. package/src/components/atoms/layouts/examples/cluster-example/ClusterExample.stories.js +97 -0
  112. package/src/components/atoms/layouts/examples/grid-example/GridExample.js +49 -0
  113. package/src/components/atoms/layouts/examples/grid-example/GridExample.stories.js +44 -0
  114. package/src/components/atoms/layouts/examples/sidebar-example/SidebarExample.js +11 -0
  115. package/src/components/atoms/layouts/examples/sidebar-example/SidebarExample.stories.js +87 -0
  116. package/src/components/atoms/layouts/examples/stack-example/StackExample.js +27 -0
  117. package/src/components/atoms/layouts/examples/stack-example/StackExample.stories.js +69 -0
  118. package/src/components/atoms/layouts/examples/switcher-example/SwitcherExample.js +38 -0
  119. package/src/components/atoms/layouts/examples/switcher-example/SwitcherExample.stories.js +65 -0
  120. package/src/components/atoms/layouts/index.js +27 -0
  121. package/src/components/atoms/line-item/LineItem.js +30 -0
  122. package/src/components/atoms/line-item/LineItem.theme.js +7 -0
  123. package/src/components/atoms/line-item/index.js +3 -0
  124. package/src/components/atoms/link/ExternalLink.js +50 -0
  125. package/src/components/atoms/link/ExternalLink.styled.js +26 -0
  126. package/src/components/atoms/link/InternalLink.js +51 -0
  127. package/src/components/atoms/link/InternalLink.styled.js +39 -0
  128. package/src/components/atoms/link/Link.theme.js +8 -0
  129. package/src/components/atoms/link/index.js +4 -0
  130. package/src/components/atoms/nav-footer/NavFooter.js +57 -0
  131. package/src/components/atoms/nav-footer/index.js +3 -0
  132. package/src/components/atoms/nav-header/NavHeader.js +36 -0
  133. package/src/components/atoms/nav-header/index.js +3 -0
  134. package/src/components/atoms/paragraph/Paragraph.js +31 -0
  135. package/src/components/atoms/paragraph/Paragraph.styled.js +13 -0
  136. package/src/components/atoms/paragraph/Paragraph.theme.js +18 -0
  137. package/src/components/atoms/paragraph/index.js +3 -0
  138. package/src/components/atoms/password-requirements/PasswordRequirements.js +116 -0
  139. package/src/components/atoms/password-requirements/index.js +3 -0
  140. package/src/components/atoms/placeholder/Placeholder.js +122 -0
  141. package/src/components/atoms/placeholder/Placeholder.theme.js +9 -0
  142. package/src/components/atoms/placeholder/index.js +3 -0
  143. package/src/components/atoms/processing-fee/ProcessingFee.js +43 -0
  144. package/src/components/atoms/processing-fee/ProcessingFee.theme.js +7 -0
  145. package/src/components/atoms/processing-fee/index.js +3 -0
  146. package/src/components/atoms/radio-button/RadioButton.js +101 -0
  147. package/src/components/atoms/radio-button/RadioButton.theme.js +9 -0
  148. package/src/components/atoms/radio-button/index.js +3 -0
  149. package/src/components/atoms/solid-divider/SolidDivider.js +22 -0
  150. package/src/components/atoms/solid-divider/SolidDivider.theme.js +8 -0
  151. package/src/components/atoms/solid-divider/index.js +3 -0
  152. package/src/components/atoms/spinner/Spinner.js +61 -0
  153. package/src/components/atoms/spinner/Spinner.theme.js +5 -0
  154. package/src/components/atoms/spinner/index.js +3 -0
  155. package/src/components/atoms/state-province-dropdown/StateProvinceDropdown.js +28 -0
  156. package/src/components/atoms/state-province-dropdown/index.js +3 -0
  157. package/src/components/atoms/state-province-dropdown/options.js +3837 -0
  158. package/src/components/atoms/text/Text.js +37 -0
  159. package/src/components/atoms/text/Text.styled.js +32 -0
  160. package/src/components/atoms/text/Text.theme.js +22 -0
  161. package/src/components/atoms/text/index.js +3 -0
  162. package/src/components/atoms/toggle-switch/ToggleSwitch.js +212 -0
  163. package/src/components/atoms/toggle-switch/ToggleSwitch.theme.js +36 -0
  164. package/src/components/atoms/toggle-switch/index.js +3 -0
  165. package/src/components/index.js +3 -0
  166. package/src/components/molecules/address-form/AddressForm.js +110 -0
  167. package/src/components/molecules/address-form/AddressForm.state.js +52 -0
  168. package/src/components/molecules/address-form/index.js +11 -0
  169. package/src/components/molecules/change-password-form/ChangePasswordForm.js +92 -0
  170. package/src/components/molecules/change-password-form/ChangePasswordForm.state.js +33 -0
  171. package/src/components/molecules/change-password-form/index.js +11 -0
  172. package/src/components/molecules/collapsible-section/CollapsibleSection.js +126 -0
  173. package/src/components/molecules/collapsible-section/CollapsibleSection.theme.js +11 -0
  174. package/src/components/molecules/collapsible-section/index.js +3 -0
  175. package/src/components/molecules/edit-name-form/EditNameForm.js +51 -0
  176. package/src/components/molecules/edit-name-form/EditNameForm.state.js +14 -0
  177. package/src/components/molecules/edit-name-form/index.js +11 -0
  178. package/src/components/molecules/email-form/EmailForm.js +55 -0
  179. package/src/components/molecules/email-form/EmailForm.state.js +19 -0
  180. package/src/components/molecules/email-form/index.js +11 -0
  181. package/src/components/molecules/forgot-password-form/ForgotPasswordForm.js +32 -0
  182. package/src/components/molecules/forgot-password-form/ForgotPasswordForm.state.js +11 -0
  183. package/src/components/molecules/forgot-password-form/index.js +11 -0
  184. package/src/components/molecules/highlight-tab-row/HighlightTabRow.js +62 -0
  185. package/src/components/molecules/highlight-tab-row/HighlightTabRow.theme.js +7 -0
  186. package/src/components/molecules/highlight-tab-row/index.js +8 -0
  187. package/src/components/molecules/index.js +24 -0
  188. package/src/components/molecules/login-form/LoginForm.js +46 -0
  189. package/src/components/molecules/login-form/LoginForm.state.js +14 -0
  190. package/src/components/molecules/login-form/index.js +11 -0
  191. package/src/components/molecules/modal/Modal.js +138 -0
  192. package/src/components/molecules/modal/index.js +3 -0
  193. package/src/components/molecules/module/Module.js +42 -0
  194. package/src/components/molecules/module/Module.theme.js +30 -0
  195. package/src/components/molecules/module/index.js +8 -0
  196. package/src/components/molecules/nav-menu/NavMenu.theme.js +5 -0
  197. package/src/components/molecules/nav-menu/NavMenuDesktop.js +39 -0
  198. package/src/components/molecules/nav-menu/NavMenuMobile.js +63 -0
  199. package/src/components/molecules/nav-menu/index.js +4 -0
  200. package/src/components/molecules/obligation/Obligation.js +69 -0
  201. package/src/components/molecules/obligation/icons/AccountBillIcon.js +89 -0
  202. package/src/components/molecules/obligation/icons/AccountConstructionIcon.js +99 -0
  203. package/src/components/molecules/obligation/icons/AccountDentalIcon.js +94 -0
  204. package/src/components/molecules/obligation/icons/AccountElectricIcon.js +99 -0
  205. package/src/components/molecules/obligation/icons/AccountGarbageIcon.js +94 -0
  206. package/src/components/molecules/obligation/icons/AccountGasIcon.js +94 -0
  207. package/src/components/molecules/obligation/icons/AccountGenericIcon.js +89 -0
  208. package/src/components/molecules/obligation/icons/AccountMedicalIcon.js +94 -0
  209. package/src/components/molecules/obligation/icons/AccountWaterIcon.js +94 -0
  210. package/src/components/molecules/obligation/icons/PropertyApartmentIcon.js +99 -0
  211. package/src/components/molecules/obligation/icons/PropertyBusinessIcon.js +94 -0
  212. package/src/components/molecules/obligation/icons/PropertyCarIcon.js +99 -0
  213. package/src/components/molecules/obligation/icons/PropertyCommercialVehicleIcon.js +100 -0
  214. package/src/components/molecules/obligation/icons/PropertyGarageIcon.js +96 -0
  215. package/src/components/molecules/obligation/icons/PropertyLandIcon.js +99 -0
  216. package/src/components/molecules/obligation/icons/PropertyMotorcycleIcon.js +99 -0
  217. package/src/components/molecules/obligation/icons/PropertyPersonalIcon.js +94 -0
  218. package/src/components/molecules/obligation/icons/PropertyStorefrontIcon.js +100 -0
  219. package/src/components/molecules/obligation/icons/index.js +60 -0
  220. package/src/components/molecules/obligation/index.js +3 -0
  221. package/src/components/molecules/obligation/modules/AmountModule.js +36 -0
  222. package/src/components/molecules/obligation/modules/IconModule.js +29 -0
  223. package/src/components/molecules/obligation/modules/PaymentDetailsActions.js +67 -0
  224. package/src/components/molecules/obligation/modules/TitleModule.js +25 -0
  225. package/src/components/molecules/obligation/modules/index.js +6 -0
  226. package/src/components/molecules/payment-button-bar/PaymentButtonBar.js +80 -0
  227. package/src/components/molecules/payment-button-bar/index.js +3 -0
  228. package/src/components/molecules/payment-details/PaymentDetails.js +158 -0
  229. package/src/components/molecules/payment-details/PaymentDetails.theme.js +11 -0
  230. package/src/components/molecules/payment-details/index.js +1 -0
  231. package/src/components/molecules/phone-form/PhoneForm.js +44 -0
  232. package/src/components/molecules/phone-form/PhoneForm.state.js +17 -0
  233. package/src/components/molecules/phone-form/index.js +11 -0
  234. package/src/components/molecules/radio-section/RadioSection.js +205 -0
  235. package/src/components/molecules/radio-section/RadioSection.theme.js +15 -0
  236. package/src/components/molecules/radio-section/index.js +3 -0
  237. package/src/components/molecules/registration-form/RegistrationForm.js +104 -0
  238. package/src/components/molecules/registration-form/RegistrationForm.state.js +40 -0
  239. package/src/components/molecules/registration-form/index.js +11 -0
  240. package/src/components/molecules/reset-confirmation-form/ResetConfirmationForm.js +56 -0
  241. package/src/components/molecules/reset-confirmation-form/index.js +3 -0
  242. package/src/components/molecules/reset-password-form/ResetPasswordForm.js +67 -0
  243. package/src/components/molecules/reset-password-form/ResetPasswordForm.state.js +30 -0
  244. package/src/components/molecules/reset-password-form/index.js +11 -0
  245. package/src/components/molecules/reset-password-success/ResetPasswordSuccess.js +55 -0
  246. package/src/components/molecules/reset-password-success/index.js +3 -0
  247. package/src/components/molecules/tab-sidebar/TabSidebar.js +92 -0
  248. package/src/components/molecules/tab-sidebar/TabSidebar.theme.js +9 -0
  249. package/src/components/molecules/tab-sidebar/index.js +3 -0
  250. package/src/components/molecules/terms-and-conditions/TermsAndConditions.js +73 -0
  251. package/src/components/molecules/terms-and-conditions/index.js +3 -0
  252. package/src/components/molecules/terms-and-conditions-modal/TermsAndConditionsModal.js +64 -0
  253. package/src/components/molecules/terms-and-conditions-modal/TermsAndConditionsModal.theme.js +28 -0
  254. package/src/components/molecules/terms-and-conditions-modal/index.js +3 -0
  255. package/src/components/molecules/workflow-tile/WorkflowTile.js +58 -0
  256. package/src/components/molecules/workflow-tile/index.js +3 -0
  257. package/src/components/templates/center-single/CenterSingle.js +61 -0
  258. package/src/components/templates/center-single/index.js +3 -0
  259. package/src/components/templates/center-stack/CenterStack.js +49 -0
  260. package/src/components/templates/center-stack/index.js +3 -0
  261. package/src/components/templates/default-page-template/DefaultPageTemplate.js +49 -0
  262. package/src/components/templates/default-page-template/index.js +3 -0
  263. package/src/components/templates/index.js +5 -0
  264. package/src/components/templates/sidebar-single-content/SidebarSingleContent.js +60 -0
  265. package/src/components/templates/sidebar-single-content/index.js +3 -0
  266. package/src/components/templates/sidebar-stack-content/SidebarStackContent.js +81 -0
  267. package/src/components/templates/sidebar-stack-content/index.js +3 -0
  268. package/src/components/templates/templates.theme.js +5 -0
  269. package/src/components/withWindowSize.js +50 -0
  270. package/src/constants/colors.js +178 -0
  271. package/src/constants/regex_constants.js +1 -0
  272. package/src/constants/style_constants.js +21 -0
  273. package/src/deprecated/colors.js +154 -0
  274. package/src/deprecated/components/radio-button/index.js +3 -0
  275. package/src/deprecated/components/radio-button/radio-button.js +44 -0
  276. package/src/deprecated/icons/AlertErrorIcon.js +42 -0
  277. package/src/deprecated/icons/AlertInfoIcon.js +42 -0
  278. package/src/deprecated/icons/AlertSuccessIcon.js +42 -0
  279. package/src/deprecated/icons/AlertWarningIcon.js +36 -0
  280. package/src/deprecated/icons/BankIcon.js +82 -0
  281. package/src/deprecated/icons/GenericCard.js +39 -0
  282. package/src/deprecated/icons/IconAdd.js +44 -0
  283. package/src/deprecated/icons/IconCheck.js +23 -0
  284. package/src/deprecated/icons/IconCheckEmail.js +46 -0
  285. package/src/deprecated/icons/IconChevron.js +35 -0
  286. package/src/deprecated/icons/IconEmailVerified.js +62 -0
  287. package/src/deprecated/icons/IconEye.js +32 -0
  288. package/src/deprecated/icons/IconEyeSlash.js +48 -0
  289. package/src/deprecated/icons/IconInvalid.js +69 -0
  290. package/src/deprecated/icons/IconNeutral.js +27 -0
  291. package/src/deprecated/icons/IconQuit.js +32 -0
  292. package/src/deprecated/icons/IconValid.js +72 -0
  293. package/src/deprecated/icons/IconWarn.js +28 -0
  294. package/src/deprecated/icons/index.js +40 -0
  295. package/src/deprecated/index.js +1 -0
  296. package/src/deprecated/spinner/Spinner.js +68 -0
  297. package/src/deprecated/spinner/index.js +1 -0
  298. package/src/deprecated/utility/__tests__/safeConcat.spec.js +59 -0
  299. package/src/deprecated/utility/__tests__/validateKeyType.spec.js +116 -0
  300. package/src/deprecated/utility/index.js +2 -0
  301. package/src/deprecated/utility/safeConcat.js +10 -0
  302. package/src/deprecated/utility/validateKeyType.js +19 -0
  303. package/src/index.js +2 -0
  304. package/src/util/formats.js +30 -0
  305. package/src/util/general.js +15 -0
  306. package/src/util/inputValidationUtils.js +257 -0
  307. package/src/util/router-utils.js +23 -0
  308. package/src/util/themeUtils.js +144 -0
@@ -0,0 +1,62 @@
1
+ import React from "react";
2
+ import { BOSTON_BLUE } from "../../constants/colors";
3
+
4
+ export const IconEmailVerified = ({ fill = BOSTON_BLUE, iconID }) => (
5
+ <svg
6
+ width="80px"
7
+ height="81px"
8
+ viewBox="0 0 80 81"
9
+ version="1.1"
10
+ xmlns="http://www.w3.org/2000/svg"
11
+ >
12
+ <defs>
13
+ <path
14
+ d="M63.1271667,0.622619753 C70.0058333,0.622619753 75.5812037,6.19894074 75.5812037,13.0766568 C75.5812037,19.9543728 70.0058333,25.5306938 63.1271667,25.5306938 C61.8898377,25.5306938 60.6946597,25.3502136 59.5665133,25.0141446 L59.5667247,48.3356222 C59.5667247,50.3328691 57.9487741,51.9508198 55.9515272,51.9508198 L7.41775537,51.9514087 C2.88612543,45.8161019 0.207234568,38.2290264 0.207234568,30.0160864 C0.207234568,23.5341676 1.8758832,17.4419964 4.80704149,12.1456508 L50.7083348,12.1459307 C51.1843595,5.70282798 56.5625236,0.622619753 63.1271667,0.622619753 Z"
15
+ id="path-1"
16
+ ></path>
17
+ <path
18
+ d="M0.269975309,13.1508395 C0.269975309,20.4154568 6.15904938,26.3064321 13.4246173,26.3064321 L13.4246173,26.3064321 C20.6892346,26.3064321 26.5792593,20.4154568 26.5792593,13.1508395 L26.5792593,13.1508395 C26.5792593,5.88622222 20.6892346,-0.00285185185 13.4246173,-0.00285185185 L13.4246173,-0.00285185185 C6.15904938,-0.00285185185 0.269975309,5.88622222 0.269975309,13.1508395 L0.269975309,13.1508395 Z M18.8497901,8.17911111 L20.4002469,9.7295679 L12.6489136,17.4809012 L11.0984568,19.031358 L6.44803704,14.3799877 L7.99849383,12.8304815 L11.0984568,15.9304444 L18.8497901,8.17911111 Z"
19
+ id="path-3"
20
+ ></path>
21
+ </defs>
22
+ <g
23
+ id="Onboarding"
24
+ stroke="none"
25
+ strokeWidth="1"
26
+ fill="none"
27
+ fillRule="evenodd"
28
+ >
29
+ <g transform="translate(-679.000000, -366.000000)">
30
+ <g
31
+ id={`icon-email-verified-${iconID}`}
32
+ transform="translate(679.000000, 366.000000)"
33
+ >
34
+ <g id="WHITE" transform="translate(2.901235, 9.990068)">
35
+ <mask id="mask-2" fill="white">
36
+ <use xlinkHref="#path-1"></use>
37
+ </mask>
38
+ <use fill="#FFFFFF" xlinkHref="#path-1"></use>
39
+ </g>
40
+ <path
41
+ d="M40.0700852,0.851253086 C49.2497613,0.851253086 57.953029,3.98062447 64.9529726,9.62508476 C65.3532083,9.94783419 65.7464188,10.2775926 66.1324659,10.6141299 L66.0284012,10.6126877 C64.6694603,10.6126877 63.3613633,10.8303887 62.1370715,11.2328147 C55.8343298,6.47433294 48.1554,3.85125309 40.0700852,3.85125309 C27.1471351,3.85125309 15.7858603,10.5355617 9.25507248,20.6353405 L53.8124273,20.635882 C53.6568723,21.4220836 53.5753148,22.2348856 53.5753148,23.0667247 C53.5753148,23.2575573 53.5796071,23.4473881 53.5881005,23.6361256 L7.5104423,23.6360171 C6.83288049,24.9399979 6.23135767,26.289824 5.71174806,27.6796213 L5.4579,28.3762531 L5.58659667,28.456599 C11.1685389,31.9251185 19.4275352,37.0571116 30.3635853,43.8525783 C30.7042691,44.064153 31.0536125,44.0876613 31.395993,43.9232446 L31.5240287,43.8527797 L55.1657203,29.1610024 C55.660726,30.0415369 56.2596815,30.8558056 56.945949,31.5871633 L33.1070668,46.4011106 C31.8221368,47.1990901 30.294866,47.2389891 28.985424,46.5206349 L28.7805473,46.4009092 C18.1577521,39.8000936 10.0837316,34.7830411 4.55848557,31.3497517 C3.80226069,34.2801999 3.4009,37.3529638 3.4009,40.5194877 C3.4009,47.8647705 5.56056475,54.7055438 9.27958717,60.4414954 L58.8527617,60.4408877 C59.9707633,60.4408877 60.885245,59.5750146 60.9626518,58.4768239 L60.9679593,58.3256901 L60.9678165,34.4494163 C61.9117678,34.8697957 62.9176683,35.1761831 63.9680366,35.3510892 L63.9679593,58.3256901 C63.9679593,61.078911 61.794342,63.3231237 59.0690342,63.4364014 L58.8527617,63.4408877 L11.4462939,63.4409532 C18.1664629,71.8217467 28.4914395,77.1877222 40.0700852,77.1877222 C60.3209798,77.1877222 76.7383198,60.7706647 76.7383198,40.5194877 C76.7383198,37.2985843 76.3205824,34.1465681 75.5225025,31.1255834 C76.3944571,30.1009094 77.1023443,28.9329618 77.6071093,27.6622696 C78.9993381,31.7322572 79.7383198,36.0653768 79.7383198,40.5194877 C79.7383198,62.4275305 61.9778225,80.1877222 40.0700852,80.1877222 C18.1609219,80.1877222 0.4009,62.4280058 0.4009,40.5194877 C0.4009,18.6109695 18.1609219,0.851253086 40.0700852,0.851253086 Z"
42
+ id="Primary"
43
+ fill={fill}
44
+ fillRule="nonzero"
45
+ ></path>
46
+ <g id="Green" transform="translate(52.333333, 9.644389)">
47
+ <mask id="mask-4" fill="white">
48
+ <use xlinkHref="#path-3"></use>
49
+ </mask>
50
+ <g id="Clip-16"></g>
51
+ <polygon
52
+ id="Fill-18"
53
+ fill="#317D4F"
54
+ mask="url(#mask-4)"
55
+ points="-0.114074074 26.6895309 26.9633086 26.6895309 26.9633086 -0.387851852 -0.114074074 -0.387851852"
56
+ ></polygon>
57
+ </g>
58
+ </g>
59
+ </g>
60
+ </g>
61
+ </svg>
62
+ );
@@ -0,0 +1,32 @@
1
+ import React from "react";
2
+ import { REGENT_GREY, WHITE } from "../../constants/colors";
3
+
4
+ export const IconEye = ({ fill = REGENT_GREY }) => (
5
+ <svg
6
+ width="28"
7
+ height="24"
8
+ viewBox="0 0 32 26"
9
+ xmlns="http://www.w3.org/2000/svg"
10
+ xmlnsXlink="http://www.w3.org/1999/xlink"
11
+ id="icon-eye"
12
+ >
13
+ <defs>
14
+ <path
15
+ d="M11.9999993,5 C6.99999964,5 2.72999991,8.10999994 1,12.4999996 C2.72999991,16.8899986 6.99999964,19.9999991 11.9999993,19.9999991 C16.999999,19.9999991 21.2699992,16.8899986 22.9999987,12.4999996 C21.2699992,8.10999994 16.999999,5 11.9999993,5 Z M11.9999993,17.4999993 C9.23999928,17.4999993 6.99999964,15.2599996 6.99999964,12.4999996 C6.99999964,9.73999949 9.23999928,7.49999985 11.9999993,7.49999985 C14.7599994,7.49999985 16.999999,9.73999949 16.999999,12.4999996 C16.999999,15.2599996 14.7599994,17.4999993 11.9999993,17.4999993 Z M11.9999993,9.49999973 C10.3399995,9.49999973 8.99999952,10.8399997 8.99999952,12.4999996 C8.99999952,14.1599993 10.3399995,15.4999994 11.9999993,15.4999994 C13.659999,15.4999994 14.9999992,14.1599993 14.9999992,12.4999996 C14.9999992,10.8399997 13.659999,9.49999973 11.9999993,9.49999973 Z"
16
+ id="icon-eye-path-1"
17
+ />
18
+ </defs>
19
+ <g id="icon-eye-People-Cards" fill="none" fillRule="evenodd">
20
+ <g id="icon-eye-Input/Text-Field">
21
+ <g id="icon-eye-Icon/Eye">
22
+ <mask id="icon-eye-mask-2" fill={WHITE}>
23
+ <use xlinkHref="#icon-eye-path-1" />
24
+ </mask>
25
+ <g id="Colors/Grey" mask="url(#icon-eye-mask-2)" fill={fill}>
26
+ <rect id="➝✏️" width="28" height="24" />
27
+ </g>
28
+ </g>
29
+ </g>
30
+ </g>
31
+ </svg>
32
+ );
@@ -0,0 +1,48 @@
1
+ import React from "react";
2
+ import { REGENT_GREY, WHITE } from "../../constants/colors";
3
+
4
+ export const IconEyeSlash = ({ fill = REGENT_GREY }) => (
5
+ <svg
6
+ width="26"
7
+ height="24"
8
+ viewBox="0 0 29 20"
9
+ xmlns="http://www.w3.org/2000/svg"
10
+ xmlnsXlink="http://www.w3.org/1999/xlink"
11
+ id="icon-eye-slash"
12
+ >
13
+ <defs>
14
+ <path
15
+ d="M12.7612833,4.4052065 C12.2133995,4.19875291 11.6198116,4.08578629 10.9999993,4.08578629 C8.23999928,4.08578629 5.99999964,6.32578592 5.99999964,9.08578599 C5.99999964,9.70559829 6.11296627,10.2991862 6.31941985,10.84707 L3.37491002,13.7915798 C1.89338624,12.5367441 0.724164462,10.9234053 0,9.08578599 C1.72999991,4.69578638 5.99999964,1.58578644 10.9999993,1.58578644 C12.3726352,1.58578644 13.6902544,1.82017212 14.9154086,2.25108117 L12.7612833,4.4052065 Z M2.41421356,17.5807034 L19.9949169,-4.4408921e-15 L20.9949169,1 L18.0627397,3.93217729 C19.8113388,5.24015798 21.1864924,7.02145463 21.9999987,9.08578599 C20.2699992,13.475785 15.999999,16.5857855 10.9999993,16.5857855 C9.35158328,16.5857855 7.78251167,16.2477564 6.35764334,15.6372736 L3.41421356,18.5807034 L2.41421356,17.5807034 Z M8.55010155,13.4448154 C9.2742367,13.8529104 10.1100878,14.0857857 10.9999993,14.0857857 C13.7599994,14.0857857 15.999999,11.845786 15.999999,9.08578599 C15.999999,8.19587447 15.7671237,7.36002334 15.3590287,6.6358882 L8.55010155,13.4448154 Z"
16
+ id="icon-eye-slash-path-1"
17
+ />
18
+ <path
19
+ d="M11.0796729,6.00103123 L8.00103123,9.0796729 C8.00034515,9.05320044 8,9.02664134 8,8.99999982 C8,7.34000002 9.34000002,6 10.9999998,6 C11.0266413,6 11.0532004,6.00034515 11.0796729,6.00103123 Z M13.0765803,6.83255101 C13.6460333,7.37818495 13.9999996,8.14682778 13.9999996,8.99999982 C13.9999996,10.6599995 12.6599995,11.9999996 10.9999998,11.9999996 C10.1468278,11.9999996 9.37818495,11.6460333 8.83255101,11.0765803 L13.0765803,6.83255101 Z"
20
+ id="icon-eye-slash-path-3"
21
+ />
22
+ </defs>
23
+ <g id="icon-eye-slash-Icon/Eye-Slash" fill="none" fillRule="evenodd">
24
+ <g id="icon-eye-slash-Combined-Shape">
25
+ <mask id="icon-eye-slash-mask-2" fill={WHITE}>
26
+ <use xlinkHref="#icon-eye-slash-path-1" />
27
+ </mask>
28
+ <g
29
+ id="icon-eye-slash-Colors/Grey"
30
+ mask="url(#icon-eye-slash-mask-2)"
31
+ fill={fill}
32
+ >
33
+ <rect width="26" height="24" id="➝✏️" />
34
+ </g>
35
+ <mask id="icon-eye-slash-mask-4" fill={WHITE}>
36
+ <use xlinkHref="#icon-eye-slash-path-3" />
37
+ </mask>
38
+ <g
39
+ id="icon-eye-slash-Colors/Grey-two"
40
+ mask="url(#icon-eye-slash-mask-4)"
41
+ fill={fill}
42
+ >
43
+ <rect width="26" height="24" id="➝✏️" />
44
+ </g>
45
+ </g>
46
+ </g>
47
+ </svg>
48
+ );
@@ -0,0 +1,69 @@
1
+ import React from "react";
2
+ import { WHITE, RAZZMATAZZ_RED } from "../../constants/colors";
3
+
4
+ export const IconInvalid = ({
5
+ bgFill = RAZZMATAZZ_RED,
6
+ iconFill = WHITE,
7
+ width = "18",
8
+ height = "18",
9
+ margin = "0"
10
+ }) => (
11
+ <svg
12
+ width={width}
13
+ height={height}
14
+ viewBox="0 0 18 18"
15
+ version="1.1"
16
+ xmlns="http://www.w3.org/2000/svg"
17
+ xmlnsXlink="http://www.w3.org/1999/xlink"
18
+ style={{ margin }}
19
+ >
20
+ <g
21
+ id="icon-invalid-Authentication"
22
+ stroke="none"
23
+ strokeWidth="1"
24
+ fill="none"
25
+ fillRule="evenodd"
26
+ >
27
+ <g
28
+ id="icon-invalid-00.1.0.1---HSS---Register---Already-Exists-Error"
29
+ transform="translate(-538.000000, -1064.000000)"
30
+ fillRule="nonzero"
31
+ >
32
+ <g
33
+ id="icon-invalid-Password-Requirements"
34
+ transform="translate(457.000000, 938.000000)"
35
+ >
36
+ <g
37
+ id="icon-invalid-Group-2"
38
+ transform="translate(81.000000, 20.000000)"
39
+ >
40
+ <g
41
+ id="icon-invalid-PasswordVerification-Error"
42
+ transform="translate(0.000000, 106.000000)"
43
+ >
44
+ <circle
45
+ id="icon-invalid-Oval"
46
+ stroke={bgFill}
47
+ fill={bgFill}
48
+ cx="9"
49
+ cy="9"
50
+ r="8.5"
51
+ ></circle>
52
+ <g
53
+ id="icon-invalid-Icon/Close"
54
+ transform="translate(2.000000, 2.000000)"
55
+ fill={iconFill}
56
+ >
57
+ <path
58
+ d="M7.58333333,7.58333333 L7.58333333,11.6666667 L6.41666667,11.6666667 L6.41666667,7.58333333 L2.33333333,7.58333333 L2.33333333,6.41666667 L6.41666667,6.41666667 L6.41666667,2.33333333 L7.58333333,2.33333333 L7.58333333,6.41666667 L11.6666667,6.41666667 L11.6666667,7.58333333 L7.58333333,7.58333333 Z"
59
+ id="icon-invalid-x"
60
+ transform="translate(7.000000, 7.000000) rotate(45.000000) translate(-7.000000, -7.000000) "
61
+ ></path>
62
+ </g>
63
+ </g>
64
+ </g>
65
+ </g>
66
+ </g>
67
+ </g>
68
+ </svg>
69
+ );
@@ -0,0 +1,27 @@
1
+ import React from "react";
2
+ import { ALTO_GREY } from "../../constants/colors";
3
+
4
+ export const IconNeutral = ({
5
+ fill = ALTO_GREY,
6
+ width = "18",
7
+ height = "18",
8
+ margin = "0"
9
+ }) => (
10
+ <svg
11
+ width={width}
12
+ height={height}
13
+ viewBox="0 0 18 18"
14
+ version="1.1"
15
+ xmlns="http://www.w3.org/2000/svg"
16
+ xmlnsXlink="http://www.w3.org/1999/xlink"
17
+ style={{ margin }}
18
+ >
19
+ <g id="icon-neutral-group" fill={fill} fillRule="nonzero" stroke={fill}>
20
+ <g id="icon-neutral-Group-2">
21
+ <g id="icon-neutral-PasswordVerification-Empty">
22
+ <circle id="icon-neutral-Oval" cx="9" cy="9" r="8.5"></circle>
23
+ </g>
24
+ </g>
25
+ </g>
26
+ </svg>
27
+ );
@@ -0,0 +1,32 @@
1
+ import React from "react";
2
+ import { MINESHAFT_GREY } from "../../constants/colors";
3
+
4
+ export const IconQuit = ({
5
+ fill = MINESHAFT_GREY,
6
+ width = "24px",
7
+ height = "24px"
8
+ }) => (
9
+ <svg
10
+ xmlns="http://www.w3.org/2000/svg"
11
+ xmlnsXlink="http://www.w3.org/1999/xlink"
12
+ width={width}
13
+ height={height}
14
+ viewBox="0 0 24 24"
15
+ >
16
+ <defs>
17
+ <path
18
+ id="a"
19
+ d="M18.9999989 6.40999946L17.589999 4.9999997 11.9999993 10.5899995 6.40999946 4.9999997 4.9999997 6.40999946 10.5899995 11.9999993 4.9999997 17.589999 6.40999946 18.9999989 11.9999993 13.409999 17.589999 18.9999989 18.9999989 17.589999 13.409999 11.9999993z"
20
+ ></path>
21
+ </defs>
22
+ <g fill="none" fillRule="evenodd" stroke="none" strokeWidth="1">
23
+ <mask id="b" fill="#fff">
24
+ <use xlinkHref="#a"></use>
25
+ </mask>
26
+ <use fill={fill} xlinkHref="#a"></use>
27
+ <g fill={fill} mask="url(#b)">
28
+ <path d="M0 0H24V24H0z"></path>
29
+ </g>
30
+ </g>
31
+ </svg>
32
+ );
@@ -0,0 +1,72 @@
1
+ import React from "react";
2
+ import { WHITE, FOREST_GREEN } from "../../constants/colors";
3
+
4
+ export const IconValid = ({
5
+ bgFill = FOREST_GREEN,
6
+ iconFill = WHITE,
7
+ width = "18",
8
+ height = "18",
9
+ margin = "0"
10
+ }) => (
11
+ <svg
12
+ width={width}
13
+ height={height}
14
+ viewBox="0 0 18 18"
15
+ version="1.1"
16
+ xmlns="http://www.w3.org/2000/svg"
17
+ xmlnsXlink="http://www.w3.org/1999/xlink"
18
+ style={{ margin }}
19
+ >
20
+ <g
21
+ id="icon-valid-Authentication"
22
+ stroke="none"
23
+ strokeWidth="1"
24
+ fill="none"
25
+ fillRule="evenodd"
26
+ >
27
+ <g
28
+ id="icon-valid-00.1.0.1---HSS---Register---Already-Exists-Error"
29
+ transform="translate(-538.000000, -996.000000)"
30
+ >
31
+ <g
32
+ id="icon-valid-Password-Requirements"
33
+ transform="translate(457.000000, 938.000000)"
34
+ >
35
+ <g
36
+ id="icon-valid-Group-2"
37
+ transform="translate(81.000000, 20.000000)"
38
+ >
39
+ <g
40
+ id="icon-valid-PasswordVerification-Sucess"
41
+ transform="translate(0.000000, 38.000000)"
42
+ >
43
+ <circle
44
+ id="icon-valid-Oval"
45
+ stroke={bgFill}
46
+ fill={bgFill}
47
+ fillRule="nonzero"
48
+ cx="9"
49
+ cy="9"
50
+ r="8.5"
51
+ ></circle>
52
+ <g
53
+ id="icon-valid-baseline-check-24px"
54
+ transform="translate(2.000000, 2.000000)"
55
+ >
56
+ <polygon
57
+ id="icon-valid-Path"
58
+ points="0 0 14 0 14 14 0 14"
59
+ ></polygon>
60
+ <polygon
61
+ id="icon-valid-Path-2"
62
+ fill={iconFill}
63
+ points="5.25 9.4325 2.8175 7 1.98916667 7.8225 5.25 11.0833333 12.25 4.08333333 11.4275 3.26083333"
64
+ ></polygon>
65
+ </g>
66
+ </g>
67
+ </g>
68
+ </g>
69
+ </g>
70
+ </g>
71
+ </svg>
72
+ );
@@ -0,0 +1,28 @@
1
+ import React from "react";
2
+ import { CARROT_ORANGE, WHITE } from "../../constants/colors";
3
+
4
+ export const IconWarn = ({ fill = CARROT_ORANGE }) => (
5
+ <svg
6
+ width="24"
7
+ height="24"
8
+ viewBox="0 0 24 24"
9
+ xmlns="http://www.w3.org/2000/svg"
10
+ xmlnsXlink="http://www.w3.org/1999/xlink"
11
+ id="icon-alert"
12
+ >
13
+ <defs>
14
+ <path
15
+ d="M10.9999993,14.9999991 L12.9999992,14.9999991 L12.9999992,16.999999 L10.9999993,16.999999 L10.9999993,14.9999991 Z M10.9999993,6.99999958 L12.9999992,6.99999958 L12.9999992,12.9999992 L10.9999993,12.9999992 L10.9999993,6.99999958 Z M11.989999,1.99999988 C6.46999987,1.99999988 1.99999988,6.47999962 1.99999988,11.9999993 C1.99999988,17.5199993 6.46999987,21.9999987 11.989999,21.9999987 C17.5199993,21.9999987 21.9999987,17.5199993 21.9999987,11.9999993 C21.9999987,6.47999915 17.5199993,1.99999988 11.989999,1.99999988 Z M11.9999993,19.9999988 C7.57999947,19.9999988 3.99999976,16.419999 3.99999976,11.9999993 C3.99999976,7.57999947 7.57999947,3.99999976 11.9999993,3.99999976 C16.419999,3.99999976 19.9999988,7.57999947 19.9999988,11.9999993 C19.9999988,16.419999 16.419999,19.9999988 11.9999993,19.9999988 Z"
16
+ id="icon-alert-path-1"
17
+ />
18
+ </defs>
19
+ <g id="icon-alert-stroke" fill="none" fillRule="evenodd">
20
+ <mask id="icon-alert-mask-2" fill={WHITE}>
21
+ <use xlinkHref="#icon-alert-path-1" />
22
+ </mask>
23
+ <g id="Colors/Blue-Dark" mask="url(#icon-alert-mask-2)" fill={fill}>
24
+ <rect id="➝✏️" width="24" height="24" />
25
+ </g>
26
+ </g>
27
+ </svg>
28
+ );
@@ -0,0 +1,40 @@
1
+ import { IconAdd } from "./IconAdd";
2
+ import { IconWarn } from "./IconWarn";
3
+ import { IconCheck } from "./IconCheck";
4
+ import { IconCheckEmail } from "./IconCheckEmail";
5
+ import { IconEmailVerified } from "./IconEmailVerified";
6
+ import { IconEye } from "./IconEye";
7
+ import { IconEyeSlash } from "./IconEyeSlash";
8
+ import { IconChevron } from "./IconChevron";
9
+ import { IconNeutral } from "./IconNeutral";
10
+ import { IconValid } from "./IconValid";
11
+ import { IconInvalid } from "./IconInvalid";
12
+
13
+ import { AlertInfoIcon } from "./AlertInfoIcon";
14
+ import { AlertErrorIcon } from "./AlertErrorIcon";
15
+ import { AlertSuccessIcon } from "./AlertSuccessIcon";
16
+ import { AlertWarningIcon } from "./AlertWarningIcon";
17
+ import { IconQuit } from "./IconQuit";
18
+
19
+ const AlertIcons = {
20
+ error: AlertErrorIcon,
21
+ info: AlertInfoIcon,
22
+ success: AlertSuccessIcon,
23
+ warn: AlertWarningIcon
24
+ };
25
+
26
+ export {
27
+ IconAdd,
28
+ IconWarn,
29
+ IconCheck,
30
+ IconCheckEmail,
31
+ IconEmailVerified,
32
+ IconEye,
33
+ IconEyeSlash,
34
+ IconChevron,
35
+ IconNeutral,
36
+ IconValid,
37
+ IconInvalid,
38
+ AlertIcons,
39
+ IconQuit
40
+ };
@@ -0,0 +1 @@
1
+ export { default as RadioButton } from "./components/radio-button";
@@ -0,0 +1,68 @@
1
+ import React from "react";
2
+ import styled from "styled-components";
3
+ import posed from "react-pose";
4
+ import { linear } from "@popmotion/easing";
5
+
6
+ const rotate = posed.div({
7
+ fixed: {
8
+ rotate: "0deg"
9
+ },
10
+ rotate: {
11
+ rotate: "360deg",
12
+ transition: {
13
+ rotate: {
14
+ ease: linear,
15
+ duration: 1000,
16
+ loop: Infinity
17
+ }
18
+ }
19
+ }
20
+ });
21
+
22
+ export const SpinnerContainer = styled.div`
23
+ width: 100%;
24
+ display: flex;
25
+ flex-direction: row;
26
+ align-items: center;
27
+ justify-content: center;
28
+ line-height: 1;
29
+ `;
30
+
31
+ export const SpinnerIconWrapper = styled(rotate)`
32
+ width: ${({ size }) => size}px;
33
+ height: ${({ size }) => size}px;
34
+ `;
35
+
36
+ const SpinnerIcon = ({ color, size = 24 }) => (
37
+ <SpinnerContainer>
38
+ <SpinnerIconWrapper initialPose="fixed" pose="rotate" size={size}>
39
+ <svg
40
+ viewBox={`0 0 24 24`}
41
+ height="100%"
42
+ width="100%"
43
+ xmlns="http://www.w3.org/2000/svg"
44
+ xmlnsXlink="http://www.w3.org/1999/xlink"
45
+ >
46
+ <defs>
47
+ <path
48
+ d="M72.1558149,36 C72.0733136,36 72.0151877,35.9981252 71.9829372,35.9970003 C66.1928468,35.9876262 60,31.1685779 60,23.9985001 C60,16.821298 66.204847,12 71.9998125,12 C78.2804106,12 84,17.7189638 84,23.9985001 C84,24.4124613 83.6639947,24.7484298 83.2499883,24.7484298 C82.8356068,24.7484298 82.4999766,24.4124613 82.4999766,23.9985001 C82.4999766,18.5041402 77.4951484,13.4998594 71.9998125,13.4998594 C66.9289833,13.4998594 61.5000234,17.7185889 61.5000234,23.9985001 C61.5000234,30.2784114 66.9289833,34.4971409 71.9998125,34.4971409 C72.0129377,34.4971409 72.0260629,34.4975159 72.0391881,34.4982658 C72.0789387,34.4990157 76.2268785,34.6471268 79.907186,30.9675968 C80.2000656,30.6747492 80.675198,30.6747492 80.9677026,30.9675968 C81.2605822,31.2604443 81.2605822,31.7351498 80.9677026,32.0279974 C77.2236441,35.7716464 73.1034547,36 72.1558149,36 L72.1558149,36 Z"
49
+ id="path-1"
50
+ />
51
+ </defs>
52
+ <g id="Symbols" fill="none" fillRule="evenodd">
53
+ <g
54
+ id="Button/Primary/Standard/Loading"
55
+ transform="translate(-60 -12)"
56
+ >
57
+ <mask id="mask-2" fill={color || "white"}>
58
+ <use xlinkHref="#path-1" />
59
+ </mask>
60
+ <use id="loader" fill={color || "white"} xlinkHref="#path-1" />
61
+ </g>
62
+ </g>
63
+ </svg>
64
+ </SpinnerIconWrapper>
65
+ </SpinnerContainer>
66
+ );
67
+
68
+ export default SpinnerIcon;
@@ -0,0 +1 @@
1
+ export { default } from "./Spinner";
@@ -0,0 +1,59 @@
1
+ //
2
+
3
+ import safeConcat from '../safeConcat';
4
+
5
+ describe('safeConcat', () => {
6
+ beforeEach(() => {
7
+ console.error = jest.fn();
8
+ });
9
+
10
+ describe('arg validation', () => {
11
+ describe('when values not an array', () => {
12
+ it('throws console error', () => {
13
+ const result = safeConcat('a', '-');
14
+
15
+ const errors = console.error.mock.calls;
16
+ expect(errors.length).toEqual(1);
17
+
18
+ const firstError = errors[0][0];
19
+ expect(firstError).toEqual('\'values\' needs to be an array. Recieved string');
20
+
21
+ expect(result).toEqual(undefined);
22
+ });
23
+ });
24
+ });
25
+
26
+ describe('with valid values', () => {
27
+ it('concatinates strings with concatinator', () => {
28
+ const result = safeConcat(['a', 'b', 'c'], '-');
29
+ expect(result).toEqual('a-b-c');
30
+ });
31
+
32
+ it('stringifies the concatinator', () => {
33
+ const result = safeConcat(['a', 'b', 'c'], 1);
34
+ expect(result).toEqual('a1b1c');
35
+ });
36
+
37
+ it('removes falsey string values from values array', () => {
38
+ const result = safeConcat(['a', undefined, 'b', ''], '-');
39
+ expect(result).toEqual('a-b');
40
+ });
41
+
42
+ it('does not append concatinator single values arrays', () => {
43
+ const result = safeConcat(['a'], '-');
44
+ expect(result).toEqual('a');
45
+ });
46
+
47
+ it('does not append concatinator to single truthy values', () => {
48
+ const result = safeConcat(['a', undefined], '-');
49
+ expect(result).toEqual('a');
50
+ });
51
+ });
52
+
53
+ describe('with no valid values', () => {
54
+ it('returns empty string when no valid values', () => {
55
+ const result = safeConcat([undefined], '-');
56
+ expect(result).toEqual('');
57
+ });
58
+ });
59
+ });
@@ -0,0 +1,116 @@
1
+ //
2
+
3
+ import validateKeyType from '../validateKeyType';
4
+
5
+ describe('validateKeyType', () => {
6
+ const objParam = {
7
+ aArray: [1],
8
+ aBoolean: true,
9
+ aFunction: jest.fn(),
10
+ aNumber: 1,
11
+ aObject: { foo: 'bar' },
12
+ aString: 'bar'
13
+ };
14
+
15
+ describe('when obj param does not contain key param', () => {
16
+ it('returns false', () => {
17
+ const result = validateKeyType(objParam, 'wrong-key', 'string');
18
+ expect(result).toEqual(false);
19
+ });
20
+ });
21
+
22
+ describe('when obj param contains key param', () => {
23
+ describe('when obj[key] type', () => {
24
+ describe('matches type param', () => {
25
+ describe('of Array', () => {
26
+ it('returns true', () => {
27
+ const arrayResult = validateKeyType(objParam, 'aArray', 'array');
28
+ expect(arrayResult).toEqual(true);
29
+ });
30
+ });
31
+
32
+ describe('of Boolean', () => {
33
+ it('returns true', () => {
34
+ const arrayResult = validateKeyType(objParam, 'aBoolean', 'boolean');
35
+ expect(arrayResult).toEqual(true);
36
+ });
37
+ });
38
+
39
+ describe('of Function', () => {
40
+ it('returns true', () => {
41
+ const arrayResult = validateKeyType(objParam, 'aFunction', 'function');
42
+ expect(arrayResult).toEqual(true);
43
+ });
44
+ });
45
+
46
+ describe('of Number', () => {
47
+ it('returns true', () => {
48
+ const arrayResult = validateKeyType(objParam, 'aNumber', 'number');
49
+ expect(arrayResult).toEqual(true);
50
+ });
51
+ });
52
+
53
+ describe('of Object', () => {
54
+ it('returns true', () => {
55
+ const arrayResult = validateKeyType(objParam, 'aObject', 'object');
56
+ expect(arrayResult).toEqual(true);
57
+ });
58
+ });
59
+
60
+ describe('of String', () => {
61
+ it('returns true', () => {
62
+ const arrayResult = validateKeyType(objParam, 'aString', 'string');
63
+ expect(arrayResult).toEqual(true);
64
+ });
65
+ });
66
+ });
67
+
68
+ describe('does not match type param', () => {
69
+ describe('of Array', () => {
70
+ it('returns false', () => {
71
+ const arrayResult = validateKeyType(objParam, 'aArray', 'string');
72
+ expect(arrayResult).toEqual(false);
73
+
74
+ const arrayObjResult = validateKeyType(objParam, 'aArray', 'object');
75
+ expect(arrayObjResult).toEqual(false);
76
+ });
77
+ });
78
+
79
+ describe('of Boolean', () => {
80
+ it('returns false', () => {
81
+ const arrayResult = validateKeyType(objParam, 'aBoolean', 'string');
82
+ expect(arrayResult).toEqual(false);
83
+ });
84
+ });
85
+
86
+ describe('of Function', () => {
87
+ it('returns false', () => {
88
+ const arrayResult = validateKeyType(objParam, 'aFunction', 'string');
89
+ expect(arrayResult).toEqual(false);
90
+ });
91
+ });
92
+
93
+ describe('of Number', () => {
94
+ it('returns false', () => {
95
+ const arrayResult = validateKeyType(objParam, 'aNumber', 'string');
96
+ expect(arrayResult).toEqual(false);
97
+ });
98
+ });
99
+
100
+ describe('of Object', () => {
101
+ it('returns false', () => {
102
+ const arrayResult = validateKeyType(objParam, 'aObject', 'string');
103
+ expect(arrayResult).toEqual(false);
104
+ });
105
+ });
106
+
107
+ describe('of String', () => {
108
+ it('returns false', () => {
109
+ const arrayResult = validateKeyType(objParam, 'aString', 'number');
110
+ expect(arrayResult).toEqual(false);
111
+ });
112
+ });
113
+ });
114
+ });
115
+ });
116
+ });