@occmundial/occ-atomic 2.0.0-beta.0 → 2.0.0-beta.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (302) hide show
  1. package/.prettierrc +6 -0
  2. package/.whitesource +12 -0
  3. package/CHANGELOG.md +1276 -581
  4. package/CONTRIBUTING.md +24 -0
  5. package/README.md +21 -21
  6. package/build/Autocomplete/Autocomplete.js +35 -23
  7. package/build/Autocomplete/Autocomplete.test.js +14 -14
  8. package/build/Autocomplete/__snapshots__/Autocomplete.test.js.snap +20 -0
  9. package/build/Avatar/Avatar.js +21 -17
  10. package/build/Avatar/Avatar.test.js +2 -2
  11. package/build/Avatar/AvatarContent/AvatarContent.js +5 -5
  12. package/build/Avatar/AvatarContent/AvatarContent.test.js +6 -6
  13. package/build/Avatar/AvatarContent/__snapshots__/AvatarContent.test.js.snap +41 -0
  14. package/build/Avatar/AvatarContent/styles.js +10 -6
  15. package/build/Avatar/__snapshots__/Avatar.test.js.snap +17 -0
  16. package/build/Avatar/index.js +4 -2
  17. package/build/Banner/Banner.js +76 -0
  18. package/build/Banner/Banner.test.js +40 -0
  19. package/build/Banner/__snapshots__/Banner.test.js.snap +33 -0
  20. package/build/Banner/index.js +18 -0
  21. package/build/Banner/styles.js +41 -0
  22. package/build/Button/Button.js +51 -30
  23. package/build/Button/Button.test.js +20 -25
  24. package/build/Button/Loading.js +89 -0
  25. package/build/Button/__snapshots__/Button.test.js.snap +334 -0
  26. package/build/Button/index.js +4 -2
  27. package/build/Button/styles.js +174 -155
  28. package/build/ButtonAlign/ButtonAlign.js +86 -0
  29. package/build/ButtonAlign/ButtonAlign.test.js +50 -0
  30. package/build/ButtonAlign/__snapshots__/ButtonAlign.test.js.snap +19 -0
  31. package/build/ButtonAlign/index.js +18 -0
  32. package/build/ButtonAlign/styles.js +18 -0
  33. package/build/Card/Card.js +1 -1
  34. package/build/Card/Card.test.js +4 -4
  35. package/build/Card/__snapshots__/Card.test.js.snap +46 -0
  36. package/build/Card/index.js +4 -2
  37. package/build/Check/Check.js +151 -0
  38. package/build/Check/Check.test.js +85 -0
  39. package/build/Check/__snapshots__/Check.test.js.snap +92 -0
  40. package/build/Check/index.js +18 -0
  41. package/build/Check/styles.js +100 -0
  42. package/build/Checkbox/Checkbox.js +29 -16
  43. package/build/Checkbox/Checkbox.test.js +8 -8
  44. package/build/Checkbox/__snapshots__/Checkbox.test.js.snap +92 -0
  45. package/build/Checkbox/index.js +4 -2
  46. package/build/Column/Column.js +67 -0
  47. package/build/Column/Column.test.js +59 -0
  48. package/build/Column/__snapshots__/Column.test.js.snap +647 -0
  49. package/build/Column/index.js +18 -0
  50. package/build/Column/styles.js +93 -0
  51. package/build/Container/Container.js +50 -0
  52. package/build/Container/Container.test.js +53 -0
  53. package/build/Container/__snapshots__/Container.test.js.snap +43 -0
  54. package/build/Container/index.js +18 -0
  55. package/build/Container/styles.js +49 -0
  56. package/build/Droplist/Droplist.js +82 -33
  57. package/build/Droplist/Droplist.test.js +50 -11
  58. package/build/Droplist/__snapshots__/Droplist.test.js.snap +65 -0
  59. package/build/Droplist/functions.js +9 -2
  60. package/build/Droplist/index.js +4 -2
  61. package/build/Droplist/styles.js +39 -10
  62. package/build/Flexbox/Flexbox.js +16 -12
  63. package/build/Flexbox/Flexbox.test.js +3 -3
  64. package/build/Flexbox/__snapshots__/Flexbox.test.js.snap +106 -0
  65. package/build/Flexbox/index.js +4 -2
  66. package/build/Footer/Footer.js +42 -30
  67. package/build/Footer/Footer.test.js +2 -2
  68. package/build/Footer/List/List.js +32 -25
  69. package/build/Footer/__snapshots__/Footer.test.js.snap +90 -0
  70. package/build/Footer/styles.js +5 -0
  71. package/build/Grid/Col/Col.js +1 -1
  72. package/build/Grid/Col/Col.test.js +3 -3
  73. package/build/Grid/Col/__snapshots__/Col.test.js.snap +963 -0
  74. package/build/Grid/Col/index.js +4 -2
  75. package/build/Grid/Grid.js +18 -12
  76. package/build/Grid/Row/Row.js +1 -1
  77. package/build/Grid/Row/Row.test.js +2 -2
  78. package/build/Grid/Row/__snapshots__/Row.test.js.snap +22 -0
  79. package/build/Grid/Row/index.js +4 -2
  80. package/build/Grid/index.js +4 -2
  81. package/build/Header/Header.js +163 -0
  82. package/build/Header/Header.test.js +118 -0
  83. package/build/Header/Menu/Menu.js +135 -0
  84. package/build/Header/Menu/Menu.test.js +107 -0
  85. package/build/Header/Menu/__snapshots__/Menu.test.js.snap +113 -0
  86. package/build/Header/Menu/index.js +18 -0
  87. package/build/Header/Menu/styles.js +123 -0
  88. package/build/Header/Nav/Nav.js +95 -0
  89. package/build/Header/Nav/Nav.test.js +81 -0
  90. package/build/Header/Nav/__snapshots__/Nav.test.js.snap +101 -0
  91. package/build/Header/Nav/index.js +18 -0
  92. package/build/Header/Nav/styles.js +110 -0
  93. package/build/Header/__snapshots__/Header.test.js.snap +79 -0
  94. package/build/Header/index.js +18 -0
  95. package/build/Header/styles.js +94 -0
  96. package/build/Hidden/Hidden.js +17 -13
  97. package/build/Hidden/Hidden.test.js +6 -6
  98. package/build/Hidden/__snapshots__/Hidden.test.js.snap +3 -0
  99. package/build/Hidden/index.js +4 -2
  100. package/build/Icon/Icon.js +27 -15
  101. package/build/Icon/Icon.test.js +3 -3
  102. package/build/Icon/__snapshots__/Icon.test.js.snap +26 -0
  103. package/build/Icon/index.js +4 -2
  104. package/build/Input/Input.js +442 -0
  105. package/build/Input/Input.test.js +258 -0
  106. package/build/Input/__snapshots__/Input.test.js.snap +194 -0
  107. package/build/Input/index.js +78 -0
  108. package/build/Input/styles.js +202 -0
  109. package/build/Input/stylesFlat.js +74 -0
  110. package/build/Label/Label.js +98 -0
  111. package/build/Label/Label.test.js +73 -0
  112. package/build/Label/__snapshots__/Label.test.js.snap +82 -0
  113. package/build/Label/index.js +18 -0
  114. package/build/Label/styles.js +90 -0
  115. package/build/LayerApp/LayerApp.js +113 -0
  116. package/build/LayerApp/LayerApp.test.js +56 -0
  117. package/build/LayerApp/__snapshots__/LayerApp.test.js.snap +37 -0
  118. package/build/LayerApp/index.js +18 -0
  119. package/build/LayerApp/styles.js +43 -0
  120. package/build/Modal/Modal.js +55 -37
  121. package/build/Modal/Modal.test.js +10 -10
  122. package/build/Modal/__snapshots__/Modal.test.js.snap +208 -0
  123. package/build/Modal/index.js +19 -13
  124. package/build/Modal/styles.js +43 -31
  125. package/build/NavAside/NavAside.js +22 -18
  126. package/build/NavAside/NavAside.test.js +12 -12
  127. package/build/NavAside/__snapshots__/NavAside.test.js.snap +116 -0
  128. package/build/NavAside/index.js +16 -12
  129. package/build/NavIcon/NavIcon.js +31 -19
  130. package/build/NavItem/NavItem.js +29 -16
  131. package/build/NavTab/NavTab.js +36 -29
  132. package/build/NavTop/NavTop.js +20 -16
  133. package/build/OrderBy/OrderBy.js +23 -19
  134. package/build/OrderBy/OrderBy.test.js +6 -6
  135. package/build/OrderBy/__snapshots__/OrderBy.test.js.snap +54 -0
  136. package/build/Pager/Break/Break.js +1 -1
  137. package/build/Pager/Break/Break.test.js +4 -4
  138. package/build/Pager/Break/__snapshots__/Break.test.js.snap +13 -0
  139. package/build/Pager/Page/Page.js +1 -1
  140. package/build/Pager/Page/Page.test.js +5 -5
  141. package/build/Pager/Page/__snapshots__/Page.test.js.snap +27 -0
  142. package/build/Pager/Pager.js +21 -17
  143. package/build/Pager/Pager.test.js +10 -10
  144. package/build/Pager/__snapshots__/Pager.test.js.snap +50 -0
  145. package/build/Pager/styles.js +1 -1
  146. package/build/Pill/Choice/Choice.js +23 -18
  147. package/build/Pill/Choice/styles.js +8 -3
  148. package/build/Pill/Group/Group.js +7 -4
  149. package/build/Pill/Group/styles.js +7 -4
  150. package/build/Pill/Pill.js +36 -23
  151. package/build/Pill/Pill.test.js +12 -12
  152. package/build/Pill/Stack/Stack.js +10 -7
  153. package/build/Pill/Stack/styles.js +4 -1
  154. package/build/Pill/__snapshots__/Pill.test.js.snap +62 -0
  155. package/build/Pill/styles.js +6 -2
  156. package/build/Placeholder/Placeholder.js +2 -2
  157. package/build/Placeholder/Placeholder.test.js +3 -3
  158. package/build/Placeholder/__snapshots__/Placeholder.test.js.snap +130 -0
  159. package/build/Placeholder/styles.js +23 -16
  160. package/build/Radio/Radio.js +29 -15
  161. package/build/Radio/Radio.test.js +6 -6
  162. package/build/Radio/__snapshots__/Radio.test.js.snap +83 -0
  163. package/build/RangeCounter/RangeCounter.js +110 -0
  164. package/build/RangeCounter/RangeCounter.test.js +57 -0
  165. package/build/RangeCounter/__snapshots__/RangeCounter.test.js.snap +20 -0
  166. package/build/RangeCounter/index.js +18 -0
  167. package/build/RangeCounter/styles.js +26 -0
  168. package/build/Row/Row.js +41 -0
  169. package/build/Row/Row.test.js +40 -0
  170. package/build/Row/__snapshots__/Row.test.js.snap +22 -0
  171. package/build/Row/index.js +18 -0
  172. package/build/Row/styles.js +21 -0
  173. package/build/SightLogo/SightLogo.js +41 -0
  174. package/build/SightLogo/SightLogo.test.js +40 -0
  175. package/build/SightLogo/__snapshots__/SightLogo.test.js.snap +24 -0
  176. package/build/SightLogo/index.js +18 -0
  177. package/build/SightLogo/styles.js +28 -0
  178. package/build/SlideDown/SlideDown.js +37 -26
  179. package/build/SlideDown/SlideDown.test.js +9 -9
  180. package/build/SlideDown/__snapshots__/SlideDown.test.js.snap +42 -0
  181. package/build/SlideToggle/SlideToggle.js +31 -17
  182. package/build/SlideToggle/SlideToggle.test.js +7 -7
  183. package/build/SlideToggle/__snapshots__/SlideToggle.test.js.snap +62 -0
  184. package/build/SubHeader/SubHeader.js +113 -0
  185. package/build/SubHeader/SubHeader.test.js +81 -0
  186. package/build/SubHeader/__snapshots__/SubHeader.test.js.snap +50 -0
  187. package/build/SubHeader/index.js +18 -0
  188. package/build/SubHeader/styles.js +59 -0
  189. package/build/SwitchGroup/SwitchGroup.js +114 -0
  190. package/build/SwitchGroup/SwitchGroup.test.js +91 -0
  191. package/build/SwitchGroup/__snapshots__/SwitchGroup.test.js.snap +52 -0
  192. package/build/SwitchGroup/index.js +18 -0
  193. package/build/SwitchGroup/styles.js +58 -0
  194. package/build/Tag/Tag.js +27 -10
  195. package/build/Tag/Tag.test.js +8 -8
  196. package/build/Tag/__snapshots__/Tag.test.js.snap +137 -0
  197. package/build/Tag/styles.js +72 -27
  198. package/build/Text/Text.js +30 -15
  199. package/build/Text/Text.test.js +8 -8
  200. package/build/Text/__snapshots__/Text.test.js.snap +158 -0
  201. package/build/Text/styles.js +32 -23
  202. package/build/TextField/TextField.js +151 -92
  203. package/build/TextField/TextField.test.js +27 -19
  204. package/build/TextField/__snapshots__/TextField.test.js.snap +258 -0
  205. package/build/TextField/styles.js +74 -17
  206. package/build/Tip/Tip.js +91 -27
  207. package/build/Tip/Tip.test.js +5 -5
  208. package/build/Tip/__snapshots__/Tip.test.js.snap +49 -0
  209. package/build/Tip/styles.js +32 -12
  210. package/build/Title/Title.js +89 -0
  211. package/build/Title/Title.test.js +50 -0
  212. package/build/Title/__snapshots__/Title.test.js.snap +31 -0
  213. package/build/Title/index.js +18 -0
  214. package/build/Title/styles.js +37 -0
  215. package/build/Toaster/Toast/Toast.js +11 -11
  216. package/build/Toaster/Toaster.js +27 -23
  217. package/build/Toaster/Toaster.test.js +6 -6
  218. package/build/Toaster/__snapshots__/Toaster.test.js.snap +5 -0
  219. package/build/Tooltip/Tooltip.js +210 -0
  220. package/build/Tooltip/Tooltip.test.js +35 -0
  221. package/build/Tooltip/__snapshots__/Tooltip.test.js.snap +33 -0
  222. package/build/Tooltip/hooks.js +132 -0
  223. package/build/Tooltip/index.js +18 -0
  224. package/build/Tooltip/styles.js +44 -0
  225. package/build/TourTip/TourTip.js +152 -0
  226. package/build/TourTip/TourTip.test.js +45 -0
  227. package/build/TourTip/__snapshots__/TourTip.test.js.snap +74 -0
  228. package/build/TourTip/index.js +18 -0
  229. package/build/TourTip/styles.js +82 -0
  230. package/build/Visible/Visible.js +119 -0
  231. package/build/Visible/Visible.test.js +31 -0
  232. package/build/Visible/__snapshots__/Visible.test.js.snap +3 -0
  233. package/build/Visible/index.js +13 -0
  234. package/build/WindowSize/WindowSize.js +17 -11
  235. package/build/WindowSize/WindowSize.test.js +4 -4
  236. package/build/WindowSize/__snapshots__/WindowSize.test.js.snap +3 -0
  237. package/build/index.js +79 -8
  238. package/build/plugin/babel.js +59 -0
  239. package/build/subatomic/colors.js +8 -3
  240. package/build/subatomic/fonts.js +1 -1
  241. package/build/subatomic/icons/attachment.js +23 -0
  242. package/build/subatomic/icons/attachmentSolid.js +23 -0
  243. package/build/subatomic/icons/avatarSmile.js +23 -0
  244. package/build/subatomic/icons/book.js +23 -0
  245. package/build/subatomic/icons/cash.js +23 -0
  246. package/build/subatomic/icons/copy.js +23 -0
  247. package/build/subatomic/icons/copySolid.js +23 -0
  248. package/build/subatomic/icons/crossSolid.js +23 -0
  249. package/build/subatomic/icons/dislike.js +1 -1
  250. package/build/subatomic/icons/dislikeSolid.js +23 -0
  251. package/build/subatomic/icons/energy.js +23 -0
  252. package/build/subatomic/icons/energySolid.js +23 -0
  253. package/build/subatomic/icons/eye.js +1 -1
  254. package/build/subatomic/icons/eyeClosed.js +1 -1
  255. package/build/subatomic/icons/eyeClosedSolid.js +23 -0
  256. package/build/subatomic/icons/eyeSolid.js +23 -0
  257. package/build/subatomic/icons/hourGlass.js +23 -0
  258. package/build/subatomic/icons/like.js +1 -1
  259. package/build/subatomic/icons/likeSolid.js +23 -0
  260. package/build/subatomic/icons/location.js +23 -0
  261. package/build/subatomic/icons/locationSolid.js +23 -0
  262. package/build/subatomic/icons/matchJob.js +23 -0
  263. package/build/subatomic/icons/messages.js +1 -1
  264. package/build/subatomic/icons/messagesSolid.js +1 -1
  265. package/build/subatomic/icons/moreOptionsHorizontal.js +23 -0
  266. package/build/subatomic/icons/noMessages.js +23 -0
  267. package/build/subatomic/icons/noMessagesSolid.js +23 -0
  268. package/build/subatomic/icons/occDart.js +23 -8
  269. package/build/subatomic/icons/occHorizontal.js +23 -8
  270. package/build/subatomic/icons/occLogo.js +63 -0
  271. package/build/subatomic/icons/occVertical.js +23 -8
  272. package/build/subatomic/icons/profile.js +23 -0
  273. package/build/subatomic/icons/profileSolid.js +23 -0
  274. package/build/subatomic/icons/profileView.js +23 -0
  275. package/build/subatomic/icons/refresh.js +23 -0
  276. package/build/subatomic/icons/refreshSolid.js +23 -0
  277. package/build/subatomic/icons/sendMessage.js +23 -0
  278. package/build/subatomic/icons/sendMessageSolid.js +23 -0
  279. package/build/subatomic/icons/starsSolid.js +23 -0
  280. package/build/subatomic/icons/suitcase.js +23 -0
  281. package/build/subatomic/icons/suitcaseSolid.js +23 -0
  282. package/build/subatomic/icons/tag.js +1 -1
  283. package/build/subatomic/icons/tagSolid.js +23 -0
  284. package/build/subatomic/icons/trash.js +1 -1
  285. package/build/subatomic/icons/trashSolid.js +1 -1
  286. package/build/subatomic/icons/warning.js +23 -0
  287. package/build/subatomic/icons/warningSolid.js +23 -0
  288. package/build/subatomic/icons/webSite.js +23 -0
  289. package/build/subatomic/icons/webSiteSolid.js +23 -0
  290. package/build/subatomic/icons.js +230 -112
  291. package/build/tokens/borderRadius.json +8 -0
  292. package/build/tokens/colors.json +567 -0
  293. package/build/tokens/fonts.json +231 -0
  294. package/build/tokens/index.js +47 -0
  295. package/build/tokens/shadows.json +13 -0
  296. package/build/tokens/spacing.json +16 -0
  297. package/commitlint.config.js +6 -0
  298. package/package.json +124 -111
  299. package/playroom/FrameComponent.js +31 -22
  300. package/playroom/styles.js +14 -14
  301. package/playroom.config.js +7 -7
  302. package/yarn-error.log +0 -10737
@@ -0,0 +1,110 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports["default"] = void 0;
7
+
8
+ var _colors = _interopRequireDefault(require("../../subatomic/colors"));
9
+
10
+ var _grid = _interopRequireDefault(require("../../subatomic/grid"));
11
+
12
+ var _menu$listItem$icon$a;
13
+
14
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
15
+
16
+ function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
17
+
18
+ var _default = (_menu$listItem$icon$a = {
19
+ menu: {
20
+ background: _colors["default"].blue,
21
+ margin: '0 10px',
22
+ paddingLeft: '0',
23
+ listStyle: 'none',
24
+ textAlign: 'center'
25
+ },
26
+ listItem: {
27
+ width: 'auto',
28
+ margin: '7px 30px 0 0',
29
+ textAlign: 'center',
30
+ padding: '5px 0 0 0',
31
+ display: 'inline-block',
32
+ fontSize: '12px',
33
+ cursor: 'pointer',
34
+ position: 'relative',
35
+ '&:hover $icon': {
36
+ filter: 'brightness(0.8)'
37
+ },
38
+ '&:hover $listAnchor': {
39
+ color: _colors["default"].darkBlueH
40
+ }
41
+ },
42
+ icon: {
43
+ backgroundRepeat: 'no-repeat',
44
+ backgroundPosition: 'center center'
45
+ },
46
+ activeItem: {
47
+ '& $icon, &:hover $icon': {
48
+ filter: 'brightness(1)'
49
+ },
50
+ '& $listAnchor, &:hover $listAnchor': {
51
+ color: _colors["default"].white
52
+ }
53
+ },
54
+ listAnchor: {
55
+ padding: '0',
56
+ marginTop: '-4px',
57
+ marginBottom: '2px',
58
+ textAlign: 'center',
59
+ lineHeight: '20px',
60
+ color: _colors["default"].darkBlue,
61
+ textDecoration: 'none !important',
62
+ position: 'relative',
63
+ display: 'block',
64
+ transition: '0.3s all'
65
+ }
66
+ }, _defineProperty(_menu$listItem$icon$a, "@media (min-width: ".concat(_grid["default"].sm, "px)"), {
67
+ menu: {
68
+ "float": 'left'
69
+ },
70
+ listItem: {
71
+ "float": 'left'
72
+ }
73
+ }), _defineProperty(_menu$listItem$icon$a, "@media (max-width: ".concat(_grid["default"].sm - 1, "px)"), {
74
+ menu: {
75
+ clear: 'both',
76
+ textAlign: 'center',
77
+ margin: '0'
78
+ },
79
+ listItem: {
80
+ margin: '0 25px 0 0',
81
+ '&:last-child': {
82
+ marginRight: '0'
83
+ }
84
+ },
85
+ activeItem: {
86
+ '&:after': {
87
+ content: '""',
88
+ width: '4px',
89
+ height: '4px',
90
+ display: 'block',
91
+ borderRadius: '50%',
92
+ background: _colors["default"].cyan,
93
+ position: 'absolute',
94
+ bottom: '0',
95
+ left: '50%',
96
+ marginBottom: '8px',
97
+ transform: 'translateX(-50%)'
98
+ },
99
+ '& $listAnchor': {
100
+ display: 'none'
101
+ },
102
+ '& $icon': {
103
+ marginBottom: '14px'
104
+ }
105
+ },
106
+ listAnchor: {},
107
+ icon: {}
108
+ }), _menu$listItem$icon$a);
109
+
110
+ exports["default"] = _default;
@@ -0,0 +1,79 @@
1
+ // Jest Snapshot v1, https://goo.gl/fbAQLP
2
+
3
+ exports[`Header matches the snapshot 1`] = `ShallowWrapper {}`;
4
+
5
+ exports[`Header styles matches the snapshot 1`] = `
6
+ Object {
7
+ "@media (max-width: 767px)": Object {
8
+ "content": Object {
9
+ "borderTop": "1px solid transparent",
10
+ },
11
+ "master": Object {
12
+ "boxShadow": "none",
13
+ "left": "0",
14
+ "position": "fixed",
15
+ "top": "0",
16
+ "width": "100%",
17
+ "zIndex": "10",
18
+ },
19
+ },
20
+ "@media (min-width: 1200px)": Object {
21
+ "master": Object {
22
+ "padding": "0 45px 0 45px",
23
+ },
24
+ },
25
+ "bubble": Object {
26
+ "background": "url(data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4IgogICAgICAgICAgICAJIHZpZXdCb3g9IjAgMCA1MCA0MS45IiBzdHlsZT0iZW5hYmxlLWJhY2tncm91bmQ6bmV3IDAgMCA1MCA0MS45OyIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiAgICAgICAgICAgIDxwYXRoIGZpbGw9IiNERkVERkYiIGQ9Ik0yNSwwQzExLjIsMCwwLDkuMSwwLDIwLjNjMCw0LDEuNSw3LjgsNCwxMC45YzAuMywwLjQsMSwxLDAuOCwxLjhjLTAuMSwwLjUtMi4zLDcuNi0yLjMsNy42CiAgICAgICAgICAgIAljLTAuMiwwLjYsMC4yLDEuMywxLDEuM2MwLjYsMCwxLTAuMiwxLTAuMnM3LjQtMyw3LjgtMy4yYzEtMC41LDIuNC0wLjEsMywwLjFjMywxLDYuMywxLjQsOS44LDEuNEMzOC45LDQwLDUwLDMxLjYsNTAsMjAuNAogICAgICAgICAgICAJQzUwLDkuMSwzOC44LDAsMjUsMHoiLz4KICAgICAgICAgICAgPC9zdmc+)",
27
+ "display": "block",
28
+ "height": "25px",
29
+ "width": "25px",
30
+ },
31
+ "content": Object {
32
+ "borderBottom": "1px solid transparent",
33
+ "boxShadow": "0px 0px 0px 0px rgba(0, 0, 0, 0.75)",
34
+ },
35
+ "master": Object {
36
+ "backgroundColor": "#1476fb",
37
+ "boxShadow": "0 6px 5px -3px rgba(0,0,0,0.12), 0 6px 18px 0 rgba(0,29,124,0.08)",
38
+ "minHeight": "60px",
39
+ "padding": "0 15px 0 15px",
40
+ },
41
+ "messages": Object {
42
+ "cursor": "pointer",
43
+ "display": "inline-flex",
44
+ "outline": "0",
45
+ "transform": "translateY(30%)",
46
+ },
47
+ "navbar": Object {
48
+ "border": "none",
49
+ "fontFamily": "'OccText', sans-serif",
50
+ "position": "relative",
51
+ "zIndex": "9",
52
+ },
53
+ "separate": Object {
54
+ "marginTop": "60px",
55
+ "position": "relative",
56
+ "zIndex": "9",
57
+ },
58
+ "shadow": Object {
59
+ "boxShadow": "0 6px 5px -3px rgba(0,0,0,0.12), 0 6px 18px 0 rgba(0,29,124,0.08) !important",
60
+ },
61
+ "title": Object {
62
+ "color": "#ffffff",
63
+ "float": "left",
64
+ "fontSize": "16px",
65
+ "overflow": "hidden",
66
+ "paddingBottom": "5px",
67
+ "paddingTop": "17px",
68
+ "textOverflow": "ellipsis",
69
+ "whiteSpace": "nowrap",
70
+ "width": "calc(100% - 150px)",
71
+ },
72
+ "user": Object {
73
+ "float": "right !important",
74
+ "paddingTop": "9px",
75
+ },
76
+ }
77
+ `;
78
+
79
+ exports[`HeaderJSS matches the snapshot 1`] = `ShallowWrapper {}`;
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports["default"] = void 0;
7
+
8
+ var _reactJss = _interopRequireDefault(require("react-jss"));
9
+
10
+ var _Header = _interopRequireDefault(require("./Header"));
11
+
12
+ var _styles = _interopRequireDefault(require("./styles"));
13
+
14
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
15
+
16
+ var _default = (0, _reactJss["default"])(_styles["default"])(_Header["default"]);
17
+
18
+ exports["default"] = _default;
@@ -0,0 +1,94 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports["default"] = void 0;
7
+
8
+ var _colors = _interopRequireDefault(require("../subatomic/colors"));
9
+
10
+ var _fonts = _interopRequireDefault(require("../subatomic/fonts"));
11
+
12
+ var _grid = _interopRequireDefault(require("../subatomic/grid"));
13
+
14
+ var _icons = _interopRequireDefault(require("../subatomic/icons"));
15
+
16
+ var _shadows = _interopRequireDefault(require("../subatomic/shadows"));
17
+
18
+ var _navbar$shadow$master;
19
+
20
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
21
+
22
+ function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
23
+
24
+ var _default = (_navbar$shadow$master = {
25
+ navbar: {
26
+ border: 'none',
27
+ fontFamily: _fonts["default"].body,
28
+ position: 'relative',
29
+ zIndex: '9'
30
+ },
31
+ shadow: {
32
+ boxShadow: "".concat(_shadows["default"].lvl3, " !important")
33
+ },
34
+ master: {
35
+ backgroundColor: _colors["default"].blue,
36
+ padding: '0 15px 0 15px',
37
+ minHeight: '60px',
38
+ boxShadow: _shadows["default"].lvl3
39
+ },
40
+ content: {
41
+ borderBottom: '1px solid transparent',
42
+ boxShadow: '0px 0px 0px 0px rgba(0, 0, 0, 0.75)'
43
+ },
44
+ title: {
45
+ width: 'calc(100% - 150px)',
46
+ fontSize: '16px',
47
+ color: _colors["default"].white,
48
+ paddingTop: '17px',
49
+ paddingBottom: '5px',
50
+ "float": 'left',
51
+ overflow: 'hidden',
52
+ textOverflow: 'ellipsis',
53
+ whiteSpace: 'nowrap'
54
+ },
55
+ user: {
56
+ paddingTop: '9px',
57
+ "float": 'right !important'
58
+ },
59
+ messages: {
60
+ cursor: 'pointer',
61
+ outline: '0',
62
+ display: 'inline-flex',
63
+ transform: 'translateY(30%)'
64
+ },
65
+ bubble: {
66
+ width: _icons["default"].bubble.width,
67
+ height: _icons["default"].bubble.height,
68
+ display: _icons["default"].bubble.display,
69
+ background: _icons["default"].base(_icons["default"].bubble.icon())
70
+ },
71
+ separate: {
72
+ marginTop: '60px',
73
+ zIndex: '9',
74
+ position: 'relative'
75
+ }
76
+ }, _defineProperty(_navbar$shadow$master, "@media (max-width: ".concat(_grid["default"].sm - 1, "px)"), {
77
+ master: {
78
+ position: 'fixed',
79
+ top: '0',
80
+ left: '0',
81
+ width: '100%',
82
+ zIndex: '10',
83
+ boxShadow: 'none'
84
+ },
85
+ content: {
86
+ borderTop: '1px solid transparent'
87
+ }
88
+ }), _defineProperty(_navbar$shadow$master, "@media (min-width: ".concat(_grid["default"].lg, "px)"), {
89
+ master: {
90
+ padding: '0 45px 0 45px'
91
+ }
92
+ }), _navbar$shadow$master);
93
+
94
+ exports["default"] = _default;
@@ -1,5 +1,7 @@
1
1
  "use strict";
2
2
 
3
+ function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
4
+
3
5
  Object.defineProperty(exports, "__esModule", {
4
6
  value: true
5
7
  });
@@ -13,36 +15,38 @@ var _grid = _interopRequireDefault(require("../subatomic/grid"));
13
15
 
14
16
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
15
17
 
16
- function _typeof(obj) { if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
17
-
18
18
  function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
19
19
 
20
20
  function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
21
21
 
22
22
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
23
23
 
24
- function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
24
+ function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
25
+
26
+ function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
25
27
 
26
- function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
28
+ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
29
+
30
+ function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
27
31
 
28
32
  function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
29
33
 
30
- function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
34
+ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
31
35
 
32
- function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
36
+ function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
33
37
 
34
38
  /** Hides the content on the specified window size. */
35
- var Hidden =
36
- /*#__PURE__*/
37
- function (_React$Component) {
39
+ var Hidden = /*#__PURE__*/function (_React$Component) {
38
40
  _inherits(Hidden, _React$Component);
39
41
 
42
+ var _super = _createSuper(Hidden);
43
+
40
44
  function Hidden(props) {
41
45
  var _this;
42
46
 
43
47
  _classCallCheck(this, Hidden);
44
48
 
45
- _this = _possibleConstructorReturn(this, _getPrototypeOf(Hidden).call(this, props));
49
+ _this = _super.call(this, props);
46
50
  _this.state = {
47
51
  width: 0
48
52
  };
@@ -101,14 +105,14 @@ function (_React$Component) {
101
105
 
102
106
  if (mediaQuery) {
103
107
  className = this.getClassNames();
104
- return _react["default"].createElement("span", {
108
+ return /*#__PURE__*/_react["default"].createElement("span", {
105
109
  className: className
106
110
  }, children);
107
111
  } else {
108
112
  if (width >= _grid["default"].xxs && width < _grid["default"].sm && xs || width >= _grid["default"].sm && width < _grid["default"].md && sm || width >= _grid["default"].md && width < _grid["default"].lg && md || width >= _grid["default"].lg && lg) {
109
- return _react["default"].createElement("span", null);
113
+ return /*#__PURE__*/_react["default"].createElement("span", null);
110
114
  } else {
111
- return _react["default"].createElement("span", null, children);
115
+ return /*#__PURE__*/_react["default"].createElement("span", null, children);
112
116
  }
113
117
  }
114
118
  }
@@ -19,15 +19,15 @@ var reduceClasses = function reduceClasses(prev, curr) {
19
19
  var classes = Object.keys(_styles["default"]).reduce(reduceClasses, {});
20
20
  describe("Hidden", function () {
21
21
  it('matches the snapshot', function () {
22
- var wrapper = (0, _enzyme.shallow)(_react["default"].createElement(_Hidden["default"], {
22
+ var wrapper = (0, _enzyme.shallow)( /*#__PURE__*/_react["default"].createElement(_Hidden["default"], {
23
23
  xs: true
24
- }, _react["default"].createElement("div", null, "Text")));
24
+ }, /*#__PURE__*/_react["default"].createElement("div", null, "Text")));
25
25
  expect(wrapper).toMatchSnapshot();
26
26
  });
27
27
  it('hides content in xs', function () {
28
- var wrapper = (0, _enzyme.shallow)(_react["default"].createElement(_Hidden["default"], {
28
+ var wrapper = (0, _enzyme.shallow)( /*#__PURE__*/_react["default"].createElement(_Hidden["default"], {
29
29
  xs: true
30
- }, _react["default"].createElement("div", null, "Text")));
30
+ }, /*#__PURE__*/_react["default"].createElement("div", null, "Text")));
31
31
  wrapper.setState({
32
32
  width: 1200
33
33
  });
@@ -38,11 +38,11 @@ describe("Hidden", function () {
38
38
  expect(wrapper.find('div').length).toBe(0);
39
39
  });
40
40
  it('hides content in xs using just css', function () {
41
- var wrapper = (0, _enzyme.shallow)(_react["default"].createElement(_Hidden["default"], {
41
+ var wrapper = (0, _enzyme.shallow)( /*#__PURE__*/_react["default"].createElement(_Hidden["default"], {
42
42
  xs: true,
43
43
  mediaQuery: true,
44
44
  classes: classes
45
- }, _react["default"].createElement("div", null, "Text")));
45
+ }, /*#__PURE__*/_react["default"].createElement("div", null, "Text")));
46
46
  wrapper.setState({
47
47
  width: 1200
48
48
  });
@@ -0,0 +1,3 @@
1
+ // Jest Snapshot v1, https://goo.gl/fbAQLP
2
+
3
+ exports[`Hidden matches the snapshot 1`] = `ShallowWrapper {}`;
@@ -13,7 +13,9 @@ var _styles = _interopRequireDefault(require("./styles"));
13
13
 
14
14
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
15
15
 
16
- function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty(target, key, source[key]); }); } return target; }
16
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
17
+
18
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
17
19
 
18
20
  function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
19
21
 
@@ -27,6 +29,6 @@ var _Hidden$propTypes = _Hidden["default"].propTypes,
27
29
  classes = _Hidden$propTypes.classes,
28
30
  propTypes = _objectWithoutProperties(_Hidden$propTypes, ["classes"]);
29
31
 
30
- StyledHidden.propTypes = _objectSpread({}, propTypes, StyledHidden.propTypes);
32
+ StyledHidden.propTypes = _objectSpread(_objectSpread({}, propTypes), StyledHidden.propTypes);
31
33
  var _default = StyledHidden;
32
34
  exports["default"] = _default;
@@ -1,5 +1,7 @@
1
1
  "use strict";
2
2
 
3
+ function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
4
+
3
5
  Object.defineProperty(exports, "__esModule", {
4
6
  value: true
5
7
  });
@@ -11,34 +13,36 @@ var _propTypes = _interopRequireDefault(require("prop-types"));
11
13
 
12
14
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
13
15
 
14
- function _typeof(obj) { if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
15
-
16
16
  function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
17
17
 
18
18
  function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
19
19
 
20
20
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
21
21
 
22
- function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
22
+ function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
23
23
 
24
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
24
+ function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
25
25
 
26
- function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
26
+ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
27
27
 
28
- function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
28
+ function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
29
29
 
30
- function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
30
+ function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
31
+
32
+ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
33
+
34
+ function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
31
35
 
32
36
  /** Component to display any of the icons on the library. */
33
- var Icon =
34
- /*#__PURE__*/
35
- function (_React$Component) {
37
+ var Icon = /*#__PURE__*/function (_React$Component) {
36
38
  _inherits(Icon, _React$Component);
37
39
 
40
+ var _super = _createSuper(Icon);
41
+
38
42
  function Icon() {
39
43
  _classCallCheck(this, Icon);
40
44
 
41
- return _possibleConstructorReturn(this, _getPrototypeOf(Icon).apply(this, arguments));
45
+ return _super.apply(this, arguments);
42
46
  }
43
47
 
44
48
  _createClass(Icon, [{
@@ -49,15 +53,19 @@ function (_React$Component) {
49
53
  className = _this$props.className,
50
54
  style = _this$props.style,
51
55
  id = _this$props.id,
56
+ ariaLabel = _this$props.ariaLabel,
52
57
  onClick = _this$props.onClick,
53
- alt = _this$props.alt;
58
+ alt = _this$props.alt,
59
+ testId = _this$props.testId;
54
60
  var IconType = onClick ? 'button' : 'span';
55
- return _react["default"].createElement(IconType, {
61
+ return /*#__PURE__*/_react["default"].createElement(IconType, {
56
62
  id: id,
57
63
  className: "".concat(classes.icon).concat(onClick ? " ".concat(classes.click) : '').concat(className ? " ".concat(className) : ''),
64
+ "aria-label": ariaLabel,
58
65
  style: style,
59
66
  onClick: onClick,
60
- alt: alt
67
+ alt: alt,
68
+ "data-testid": testId
61
69
  });
62
70
  }
63
71
  }]);
@@ -98,8 +106,12 @@ Icon.propTypes = {
98
106
  /** Alt property, in case you need to set it. */
99
107
  alt: _propTypes["default"].string,
100
108
  id: _propTypes["default"].string,
109
+ ariaLabel: _propTypes["default"].string,
101
110
  className: _propTypes["default"].string,
102
- style: _propTypes["default"].object
111
+ style: _propTypes["default"].object,
112
+
113
+ /** The testId property adds the data attribute data-testid to the main element and should be used for testing only. */
114
+ testId: _propTypes["default"].string
103
115
  };
104
116
  var _default = Icon;
105
117
  exports["default"] = _default;
@@ -21,7 +21,7 @@ var reduceClasses = function reduceClasses(prev, curr) {
21
21
  var classes = Object.keys(_styles["default"]).reduce(reduceClasses, {});
22
22
  describe("Icon", function () {
23
23
  it('matches the snapshot', function () {
24
- var wrapper = (0, _enzyme.shallow)(_react["default"].createElement(_Icon["default"], {
24
+ var wrapper = (0, _enzyme.shallow)( /*#__PURE__*/_react["default"].createElement(_Icon["default"], {
25
25
  iconName: "search",
26
26
  classes: classes
27
27
  }));
@@ -29,7 +29,7 @@ describe("Icon", function () {
29
29
  });
30
30
  it('calls the onClick function', function () {
31
31
  var onClick = jest.fn();
32
- var wrapper = (0, _enzyme.shallow)(_react["default"].createElement(_Icon["default"], {
32
+ var wrapper = (0, _enzyme.shallow)( /*#__PURE__*/_react["default"].createElement(_Icon["default"], {
33
33
  iconName: "search",
34
34
  classes: classes,
35
35
  onClick: onClick
@@ -40,7 +40,7 @@ describe("Icon", function () {
40
40
  });
41
41
  describe("IconJSS", function () {
42
42
  it('matches the snapshot', function () {
43
- var wrapper = (0, _enzyme.shallow)(_react["default"].createElement(_index["default"], {
43
+ var wrapper = (0, _enzyme.shallow)( /*#__PURE__*/_react["default"].createElement(_index["default"], {
44
44
  iconName: "search"
45
45
  }));
46
46
  expect(wrapper).toMatchSnapshot();
@@ -0,0 +1,26 @@
1
+ // Jest Snapshot v1, https://goo.gl/fbAQLP
2
+
3
+ exports[`Icon matches the snapshot 1`] = `ShallowWrapper {}`;
4
+
5
+ exports[`Icon styles matches the snapshot 1`] = `
6
+ Object {
7
+ "click": Object {
8
+ "cursor": "pointer",
9
+ },
10
+ "icon": Object {
11
+ "&:hover": Object {
12
+ "background": [Function],
13
+ },
14
+ "background": [Function],
15
+ "border": "0",
16
+ "boxSizing": "border-box",
17
+ "display": [Function],
18
+ "height": [Function],
19
+ "outline": "0",
20
+ "transition": [Function],
21
+ "width": [Function],
22
+ },
23
+ }
24
+ `;
25
+
26
+ exports[`IconJSS matches the snapshot 1`] = `ShallowWrapper {}`;
@@ -13,7 +13,9 @@ var _styles = _interopRequireDefault(require("./styles"));
13
13
 
14
14
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
15
15
 
16
- function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty(target, key, source[key]); }); } return target; }
16
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
17
+
18
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
17
19
 
18
20
  function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
19
21
 
@@ -27,6 +29,6 @@ var _Icon$propTypes = _Icon["default"].propTypes,
27
29
  classes = _Icon$propTypes.classes,
28
30
  propTypes = _objectWithoutProperties(_Icon$propTypes, ["classes"]);
29
31
 
30
- StyledIcon.propTypes = _objectSpread({}, propTypes, StyledIcon.propTypes);
32
+ StyledIcon.propTypes = _objectSpread(_objectSpread({}, propTypes), StyledIcon.propTypes);
31
33
  var _default = StyledIcon;
32
34
  exports["default"] = _default;