@wireapp/react-ui-kit 8.14.1 → 8.14.4

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 (336) hide show
  1. package/package.json +5 -4
  2. package/src/Form/Button.js +210 -125
  3. package/src/Form/Button.js.map +1 -1
  4. package/src/Form/ButtonLink.js +60 -47
  5. package/src/Form/ButtonLink.js.map +1 -1
  6. package/src/Form/Checkbox.js +139 -84
  7. package/src/Form/Checkbox.js.map +1 -1
  8. package/src/Form/CodeInput.js +201 -98
  9. package/src/Form/CodeInput.js.map +1 -1
  10. package/src/Form/DropFileInput.js +214 -116
  11. package/src/Form/DropFileInput.js.map +1 -1
  12. package/src/Form/ErrorMessage.js +78 -45
  13. package/src/Form/ErrorMessage.js.map +1 -1
  14. package/src/Form/Form.d.ts +1 -0
  15. package/src/Form/Form.js +31 -28
  16. package/src/Form/Form.js.map +1 -1
  17. package/src/Form/Input.js +178 -101
  18. package/src/Form/Input.js.map +1 -1
  19. package/src/Form/InputBlock.d.ts +1 -1
  20. package/src/Form/InputBlock.js +45 -19
  21. package/src/Form/InputBlock.js.map +1 -1
  22. package/src/Form/InputLabel.js +46 -44
  23. package/src/Form/InputLabel.js.map +1 -1
  24. package/src/Form/InputSubmitCombo.js +53 -49
  25. package/src/Form/InputSubmitCombo.js.map +1 -1
  26. package/src/Form/RangeInput.js +71 -47
  27. package/src/Form/RangeInput.js.map +1 -1
  28. package/src/Form/RangeInput.styles.js +55 -39
  29. package/src/Form/RangeInput.styles.js.map +1 -1
  30. package/src/Form/RoundIconButton.js +62 -42
  31. package/src/Form/RoundIconButton.js.map +1 -1
  32. package/src/Form/Select.js +95 -55
  33. package/src/Form/Select.js.map +1 -1
  34. package/src/Form/SelectComponents.js +173 -101
  35. package/src/Form/SelectComponents.js.map +1 -1
  36. package/src/Form/SelectStyles.d.ts +899 -1
  37. package/src/Form/SelectStyles.js +156 -96
  38. package/src/Form/SelectStyles.js.map +1 -1
  39. package/src/Form/ShakeBox.d.ts +1 -1
  40. package/src/Form/ShakeBox.js +81 -33
  41. package/src/Form/ShakeBox.js.map +1 -1
  42. package/src/Form/Switch.js +124 -89
  43. package/src/Form/Switch.js.map +1 -1
  44. package/src/Form/TextArea.js +80 -59
  45. package/src/Form/TextArea.js.map +1 -1
  46. package/src/Form/Tooltip.js +75 -66
  47. package/src/Form/Tooltip.js.map +1 -1
  48. package/src/Form/index.js +238 -52
  49. package/src/Form/index.js.map +1 -1
  50. package/src/GlobalCssVariables.js +96 -79
  51. package/src/GlobalCssVariables.js.map +1 -1
  52. package/src/GlobalStyle.d.js +2 -0
  53. package/src/GlobalStyle.d.js.map +1 -1
  54. package/src/GlobalStyle.d.ts +2 -1
  55. package/src/GlobalStyle.js +55 -40
  56. package/src/GlobalStyle.js.map +1 -1
  57. package/src/Icon/AddPeopleIcon.js +24 -19
  58. package/src/Icon/AddPeopleIcon.js.map +1 -1
  59. package/src/Icon/ArchiveIcon.js +24 -6
  60. package/src/Icon/ArchiveIcon.js.map +1 -1
  61. package/src/Icon/ArrowDown.js +23 -19
  62. package/src/Icon/ArrowDown.js.map +1 -1
  63. package/src/Icon/ArrowIcon.js +35 -42
  64. package/src/Icon/ArrowIcon.js.map +1 -1
  65. package/src/Icon/AttachmentIcon.js +24 -6
  66. package/src/Icon/AttachmentIcon.js.map +1 -1
  67. package/src/Icon/AudioVideoIcon.js +24 -6
  68. package/src/Icon/AudioVideoIcon.js.map +1 -1
  69. package/src/Icon/BlockIcon.js +24 -6
  70. package/src/Icon/BlockIcon.js.map +1 -1
  71. package/src/Icon/Brand/AndroidIcon.js +25 -6
  72. package/src/Icon/Brand/AndroidIcon.js.map +1 -1
  73. package/src/Icon/Brand/AppleIcon.js +25 -6
  74. package/src/Icon/Brand/AppleIcon.js.map +1 -1
  75. package/src/Icon/Brand/ChromeIcon.js +25 -6
  76. package/src/Icon/Brand/ChromeIcon.js.map +1 -1
  77. package/src/Icon/Brand/FacebookIcon.js +24 -6
  78. package/src/Icon/Brand/FacebookIcon.js.map +1 -1
  79. package/src/Icon/Brand/GitHubIcon.js +24 -6
  80. package/src/Icon/Brand/GitHubIcon.js.map +1 -1
  81. package/src/Icon/Brand/LinkedInIcon.js +24 -6
  82. package/src/Icon/Brand/LinkedInIcon.js.map +1 -1
  83. package/src/Icon/Brand/LinuxIcon.js +25 -6
  84. package/src/Icon/Brand/LinuxIcon.js.map +1 -1
  85. package/src/Icon/Brand/MicrosoftIcon.js +25 -6
  86. package/src/Icon/Brand/MicrosoftIcon.js.map +1 -1
  87. package/src/Icon/Brand/TwitterIcon.js +24 -6
  88. package/src/Icon/Brand/TwitterIcon.js.map +1 -1
  89. package/src/Icon/CallIcon.js +24 -6
  90. package/src/Icon/CallIcon.js.map +1 -1
  91. package/src/Icon/CamIcon.js +24 -6
  92. package/src/Icon/CamIcon.js.map +1 -1
  93. package/src/Icon/CameraIcon.js +24 -19
  94. package/src/Icon/CameraIcon.js.map +1 -1
  95. package/src/Icon/CheckIcon.js +24 -6
  96. package/src/Icon/CheckIcon.js.map +1 -1
  97. package/src/Icon/CheckRoundIcon.js +24 -6
  98. package/src/Icon/CheckRoundIcon.js.map +1 -1
  99. package/src/Icon/ChevronIcon.js +31 -38
  100. package/src/Icon/ChevronIcon.js.map +1 -1
  101. package/src/Icon/CloseIcon.js +24 -6
  102. package/src/Icon/CloseIcon.js.map +1 -1
  103. package/src/Icon/CopyIcon.js +24 -6
  104. package/src/Icon/CopyIcon.js.map +1 -1
  105. package/src/Icon/DeviceIcon.js +24 -6
  106. package/src/Icon/DeviceIcon.js.map +1 -1
  107. package/src/Icon/DownloadIcon.js +24 -6
  108. package/src/Icon/DownloadIcon.js.map +1 -1
  109. package/src/Icon/EditDocumentIcon.js +25 -19
  110. package/src/Icon/EditDocumentIcon.js.map +1 -1
  111. package/src/Icon/EditIcon.js +24 -6
  112. package/src/Icon/EditIcon.js.map +1 -1
  113. package/src/Icon/EnterIcon.js +24 -6
  114. package/src/Icon/EnterIcon.js.map +1 -1
  115. package/src/Icon/ErrorIcon.js +39 -9
  116. package/src/Icon/ErrorIcon.js.map +1 -1
  117. package/src/Icon/FileIcon.js +24 -6
  118. package/src/Icon/FileIcon.js.map +1 -1
  119. package/src/Icon/GifIcon.js +24 -6
  120. package/src/Icon/GifIcon.js.map +1 -1
  121. package/src/Icon/GridIcon.js +24 -19
  122. package/src/Icon/GridIcon.js.map +1 -1
  123. package/src/Icon/GroupIcon.js +24 -6
  124. package/src/Icon/GroupIcon.js.map +1 -1
  125. package/src/Icon/HangupIcon.js +24 -6
  126. package/src/Icon/HangupIcon.js.map +1 -1
  127. package/src/Icon/HideIcon.js +24 -6
  128. package/src/Icon/HideIcon.js.map +1 -1
  129. package/src/Icon/ImageIcon.js +24 -6
  130. package/src/Icon/ImageIcon.js.map +1 -1
  131. package/src/Icon/InfoIcon.js +24 -6
  132. package/src/Icon/InfoIcon.js.map +1 -1
  133. package/src/Icon/InviteIcon.js +24 -6
  134. package/src/Icon/InviteIcon.js.map +1 -1
  135. package/src/Icon/LeaveIcon.js +24 -6
  136. package/src/Icon/LeaveIcon.js.map +1 -1
  137. package/src/Icon/LinkIcon.js +24 -19
  138. package/src/Icon/LinkIcon.js.map +1 -1
  139. package/src/Icon/ListIcon.js +24 -6
  140. package/src/Icon/ListIcon.js.map +1 -1
  141. package/src/Icon/LockIcon.js +25 -6
  142. package/src/Icon/LockIcon.js.map +1 -1
  143. package/src/Icon/MessageIcon.js +24 -6
  144. package/src/Icon/MessageIcon.js.map +1 -1
  145. package/src/Icon/MinusIcon.js +24 -6
  146. package/src/Icon/MinusIcon.js.map +1 -1
  147. package/src/Icon/MoreIcon.js +24 -6
  148. package/src/Icon/MoreIcon.js.map +1 -1
  149. package/src/Icon/MuteIcon.js +24 -6
  150. package/src/Icon/MuteIcon.js.map +1 -1
  151. package/src/Icon/NotificationIcon.js +24 -6
  152. package/src/Icon/NotificationIcon.js.map +1 -1
  153. package/src/Icon/NotificationOffIcon.js +24 -6
  154. package/src/Icon/NotificationOffIcon.js.map +1 -1
  155. package/src/Icon/OptionsIcon.js +24 -6
  156. package/src/Icon/OptionsIcon.js.map +1 -1
  157. package/src/Icon/PeopleIcon.js +24 -19
  158. package/src/Icon/PeopleIcon.js.map +1 -1
  159. package/src/Icon/PingIcon.js +24 -6
  160. package/src/Icon/PingIcon.js.map +1 -1
  161. package/src/Icon/PlaneIcon.js +24 -6
  162. package/src/Icon/PlaneIcon.js.map +1 -1
  163. package/src/Icon/PlusIcon.js +24 -6
  164. package/src/Icon/PlusIcon.js.map +1 -1
  165. package/src/Icon/ProfileIcon.js +24 -6
  166. package/src/Icon/ProfileIcon.js.map +1 -1
  167. package/src/Icon/RecordBoldIcon.js +50 -43
  168. package/src/Icon/RecordBoldIcon.js.map +1 -1
  169. package/src/Icon/RecordIcon.js +34 -8
  170. package/src/Icon/RecordIcon.js.map +1 -1
  171. package/src/Icon/RecordPendingIcon.js +31 -8
  172. package/src/Icon/RecordPendingIcon.js.map +1 -1
  173. package/src/Icon/ReloadIcon.js +24 -6
  174. package/src/Icon/ReloadIcon.js.map +1 -1
  175. package/src/Icon/SVGIcon.js +78 -53
  176. package/src/Icon/SVGIcon.js.map +1 -1
  177. package/src/Icon/ScreenshareIcon.js +24 -6
  178. package/src/Icon/ScreenshareIcon.js.map +1 -1
  179. package/src/Icon/SearchIcon.js +25 -6
  180. package/src/Icon/SearchIcon.js.map +1 -1
  181. package/src/Icon/ServicesIcon.js +24 -6
  182. package/src/Icon/ServicesIcon.js.map +1 -1
  183. package/src/Icon/SettingsIcon.js +24 -6
  184. package/src/Icon/SettingsIcon.js.map +1 -1
  185. package/src/Icon/ShowIcon.js +24 -6
  186. package/src/Icon/ShowIcon.js.map +1 -1
  187. package/src/Icon/SignIcon.js +24 -6
  188. package/src/Icon/SignIcon.js.map +1 -1
  189. package/src/Icon/SpeakerIcon.js +24 -6
  190. package/src/Icon/SpeakerIcon.js.map +1 -1
  191. package/src/Icon/SupportIcon.js +24 -6
  192. package/src/Icon/SupportIcon.js.map +1 -1
  193. package/src/Icon/TeamIcon.js +24 -6
  194. package/src/Icon/TeamIcon.js.map +1 -1
  195. package/src/Icon/TimedIcon.js +24 -6
  196. package/src/Icon/TimedIcon.js.map +1 -1
  197. package/src/Icon/TrashCrossIcon.js +24 -6
  198. package/src/Icon/TrashCrossIcon.js.map +1 -1
  199. package/src/Icon/TrashIcon.js +24 -6
  200. package/src/Icon/TrashIcon.js.map +1 -1
  201. package/src/Icon/TriangleIcon.js +35 -42
  202. package/src/Icon/TriangleIcon.js.map +1 -1
  203. package/src/Icon/UploadIcon.js +24 -6
  204. package/src/Icon/UploadIcon.js.map +1 -1
  205. package/src/Icon/WireIcon.js +24 -6
  206. package/src/Icon/WireIcon.js.map +1 -1
  207. package/src/Icon/index.js +953 -107
  208. package/src/Icon/index.js.map +1 -1
  209. package/src/Identity/Animation.js +211 -88
  210. package/src/Identity/Animation.js.map +1 -1
  211. package/src/Identity/Avatar.js +114 -66
  212. package/src/Identity/Avatar.js.map +1 -1
  213. package/src/Identity/AvatarGrid.js +108 -66
  214. package/src/Identity/AvatarGrid.js.map +1 -1
  215. package/src/Identity/Logo.js +54 -45
  216. package/src/Identity/Logo.js.map +1 -1
  217. package/src/Identity/colors-v2.js +186 -163
  218. package/src/Identity/colors-v2.js.map +1 -1
  219. package/src/Identity/colors.js +80 -64
  220. package/src/Identity/colors.js.map +1 -1
  221. package/src/Identity/index.js +81 -38
  222. package/src/Identity/index.js.map +1 -1
  223. package/src/Identity/motions.js +35 -71
  224. package/src/Identity/motions.js.map +1 -1
  225. package/src/Layout/Box.d.ts +1 -1
  226. package/src/Layout/Box.js +31 -9
  227. package/src/Layout/Box.js.map +1 -1
  228. package/src/Layout/Column.d.ts +1 -1
  229. package/src/Layout/Column.js +57 -17
  230. package/src/Layout/Column.js.map +1 -1
  231. package/src/Layout/Container.d.ts +5 -5
  232. package/src/Layout/Container.js +102 -29
  233. package/src/Layout/Container.js.map +1 -1
  234. package/src/Layout/Content.d.ts +1 -1
  235. package/src/Layout/Content.js +31 -8
  236. package/src/Layout/Content.js.map +1 -1
  237. package/src/Layout/FlexBox.js +45 -10
  238. package/src/Layout/FlexBox.js.map +1 -1
  239. package/src/Layout/Footer.d.ts +4 -1
  240. package/src/Layout/Footer.js +17 -4
  241. package/src/Layout/Footer.js.map +1 -1
  242. package/src/Layout/Header.d.ts +1 -1
  243. package/src/Layout/Header.js +28 -7
  244. package/src/Layout/Header.js.map +1 -1
  245. package/src/Layout/MatchMedia.js +112 -27
  246. package/src/Layout/MatchMedia.js.map +1 -1
  247. package/src/Layout/Spacer.js +26 -6
  248. package/src/Layout/Spacer.js.map +1 -1
  249. package/src/Layout/StyledApp.js +53 -45
  250. package/src/Layout/StyledApp.js.map +1 -1
  251. package/src/Layout/Theme.js +225 -217
  252. package/src/Layout/Theme.js.map +1 -1
  253. package/src/Layout/headerMenu/HeaderMenu.js +117 -54
  254. package/src/Layout/headerMenu/HeaderMenu.js.map +1 -1
  255. package/src/Layout/headerMenu/HeaderSubMenu.d.ts +1 -1
  256. package/src/Layout/headerMenu/HeaderSubMenu.js +131 -74
  257. package/src/Layout/headerMenu/HeaderSubMenu.js.map +1 -1
  258. package/src/Layout/headerMenu/MenuContent.js +47 -26
  259. package/src/Layout/headerMenu/MenuContent.js.map +1 -1
  260. package/src/Layout/headerMenu/MenuItems.js +52 -22
  261. package/src/Layout/headerMenu/MenuItems.js.map +1 -1
  262. package/src/Layout/headerMenu/MenuLink.js +89 -65
  263. package/src/Layout/headerMenu/MenuLink.js.map +1 -1
  264. package/src/Layout/headerMenu/MenuOpenButton.js +54 -26
  265. package/src/Layout/headerMenu/MenuOpenButton.js.map +1 -1
  266. package/src/Layout/headerMenu/MenuScrollableItems.js +36 -13
  267. package/src/Layout/headerMenu/MenuScrollableItems.js.map +1 -1
  268. package/src/Layout/headerMenu/MenuSubLink.js +64 -45
  269. package/src/Layout/headerMenu/MenuSubLink.js.map +1 -1
  270. package/src/Layout/headerMenu/index.js +108 -41
  271. package/src/Layout/headerMenu/index.js.map +1 -1
  272. package/src/Layout/index.js +173 -46
  273. package/src/Layout/index.js.map +1 -1
  274. package/src/Layout/sizes.js +21 -14
  275. package/src/Layout/sizes.js.map +1 -1
  276. package/src/Menu/MenuModal.js +123 -78
  277. package/src/Menu/MenuModal.js.map +1 -1
  278. package/src/Menu/TabBar.d.ts +1 -1
  279. package/src/Menu/TabBar.js +96 -50
  280. package/src/Menu/TabBar.js.map +1 -1
  281. package/src/Menu/index.js +29 -34
  282. package/src/Menu/index.js.map +1 -1
  283. package/src/Misc/ButtonGroup.js +97 -67
  284. package/src/Misc/ButtonGroup.js.map +1 -1
  285. package/src/Misc/IconButton.js +102 -72
  286. package/src/Misc/IconButton.js.map +1 -1
  287. package/src/Misc/IsInViewport.js +63 -57
  288. package/src/Misc/IsInViewport.js.map +1 -1
  289. package/src/Misc/Loading.d.ts +1 -1
  290. package/src/Misc/Loading.js +66 -58
  291. package/src/Misc/Loading.js.map +1 -1
  292. package/src/Misc/Pagination.js +149 -64
  293. package/src/Misc/Pagination.js.map +1 -1
  294. package/src/Misc/Pill.js +80 -66
  295. package/src/Misc/Pill.js.map +1 -1
  296. package/src/Misc/childrenWithDefaultProps.d.ts +1 -1
  297. package/src/Misc/childrenWithDefaultProps.js +28 -28
  298. package/src/Misc/childrenWithDefaultProps.js.map +1 -1
  299. package/src/Misc/index.js +121 -42
  300. package/src/Misc/index.js.map +1 -1
  301. package/src/Misc/useLongTouch.js +38 -23
  302. package/src/Misc/useLongTouch.js.map +1 -1
  303. package/src/Misc/useTimeout.js +44 -24
  304. package/src/Misc/useTimeout.js.map +1 -1
  305. package/src/Modal/Modal.js +177 -95
  306. package/src/Modal/Modal.js.map +1 -1
  307. package/src/Modal/Overlay.d.ts +2 -2
  308. package/src/Modal/Overlay.js +92 -68
  309. package/src/Modal/Overlay.js.map +1 -1
  310. package/src/Modal/index.js +28 -36
  311. package/src/Modal/index.js.map +1 -1
  312. package/src/Text/Heading.js +188 -71
  313. package/src/Text/Heading.js.map +1 -1
  314. package/src/Text/Label.js +74 -45
  315. package/src/Text/Label.js.map +1 -1
  316. package/src/Text/Line.js +36 -11
  317. package/src/Text/Line.js.map +1 -1
  318. package/src/Text/Link.js +88 -60
  319. package/src/Text/Link.js.map +1 -1
  320. package/src/Text/Paragraph.js +75 -44
  321. package/src/Text/Paragraph.js.map +1 -1
  322. package/src/Text/Text.d.ts +6 -6
  323. package/src/Text/Text.js +107 -29
  324. package/src/Text/Text.js.map +1 -1
  325. package/src/Text/TextLink.js +52 -38
  326. package/src/Text/TextLink.js.map +1 -1
  327. package/src/Text/Title.js +55 -38
  328. package/src/Text/Title.js.map +1 -1
  329. package/src/Text/index.js +108 -41
  330. package/src/Text/index.js.map +1 -1
  331. package/src/index.js +121 -42
  332. package/src/index.js.map +1 -1
  333. package/src/mediaQueries.js +41 -40
  334. package/src/mediaQueries.js.map +1 -1
  335. package/src/util.js +39 -8
  336. package/src/util.js.map +1 -1
@@ -1,4 +1,24 @@
1
1
  "use strict";
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
7
+ });
8
+ exports.MenuItems = exports.menuItemsStyle = void 0;
9
+
10
+ var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
11
+
12
+ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
13
+
14
+ var _react = _interopRequireDefault(require("react"));
15
+
16
+ var _react2 = require("@emotion/react");
17
+
18
+ var _mediaQueries = require("../../mediaQueries");
19
+
20
+ var _util = require("../../util");
21
+
2
22
  /*
3
23
  * Wire
4
24
  * Copyright (C) 2018 Wire Swiss GmbH
@@ -17,30 +37,40 @@
17
37
  * along with this program. If not, see http://www.gnu.org/licenses/.
18
38
  *
19
39
  */
20
- Object.defineProperty(exports, "__esModule", { value: true });
21
- exports.MenuItems = exports.menuItemsStyle = void 0;
22
- const react_1 = require("@emotion/react");
23
- const mediaQueries_1 = require("../../mediaQueries");
24
- const util_1 = require("../../util");
25
- const menuItemsStyle = (theme, props) => ({
40
+
41
+ /** @jsx jsx */
42
+ var menuItemsStyle = function menuItemsStyle(theme, props) {
43
+ return (0, _defineProperty2["default"])({
26
44
  alignSelf: 'center',
27
45
  display: 'flex',
28
- justifySelf: 'end',
29
- [mediaQueries_1.media[mediaQueries_1.QueryKeys.TABLET_DOWN]]: {
30
- backgroundColor: theme.general.backgroundColor,
31
- bottom: 0,
32
- left: 0,
33
- overflowY: 'auto',
34
- position: 'fixed',
35
- right: 0,
36
- top: 0,
37
- transform: props.open ? 'translateX(0)' : 'translateX(110%)',
38
- transition: 'transform 0.25s ease',
39
- zIndex: 1,
40
- },
41
- });
46
+ justifySelf: 'end'
47
+ }, _mediaQueries.media[_mediaQueries.QueryKeys.TABLET_DOWN], {
48
+ backgroundColor: theme.general.backgroundColor,
49
+ bottom: 0,
50
+ left: 0,
51
+ overflowY: 'auto',
52
+ position: 'fixed',
53
+ right: 0,
54
+ top: 0,
55
+ transform: props.open ? 'translateX(0)' : 'translateX(110%)',
56
+ transition: 'transform 0.25s ease',
57
+ zIndex: 1
58
+ });
59
+ };
60
+
42
61
  exports.menuItemsStyle = menuItemsStyle;
43
- const filterMenuItemProps = (props) => (0, util_1.filterProps)(props, ['open']);
44
- const MenuItems = (props) => ((0, react_1.jsx)("div", Object.assign({ css: (theme) => (0, exports.menuItemsStyle)(theme, props) }, filterMenuItemProps(props))));
62
+
63
+ var filterMenuItemProps = function filterMenuItemProps(props) {
64
+ return (0, _util.filterProps)(props, ['open']);
65
+ };
66
+
67
+ var MenuItems = function MenuItems(props) {
68
+ return (0, _react2.jsx)("div", (0, _extends2["default"])({
69
+ css: function css(theme) {
70
+ return menuItemsStyle(theme, props);
71
+ }
72
+ }, filterMenuItemProps(props)));
73
+ };
74
+
45
75
  exports.MenuItems = MenuItems;
46
76
  //# sourceMappingURL=MenuItems.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"MenuItems.js","sourceRoot":"","sources":["MenuItems.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;GAiBG;;;AAIH,0CAA8C;AAE9C,qDAAoD;AACpD,qCAAuC;AAOhC,MAAM,cAAc,GAA6D,CAAC,KAAK,EAAE,KAAK,EAAE,EAAE,CAAC,CAAC;IACzG,SAAS,EAAE,QAAQ;IACnB,OAAO,EAAE,MAAM;IACf,WAAW,EAAE,KAAK;IAClB,CAAC,oBAAK,CAAC,wBAAS,CAAC,WAAW,CAAC,CAAC,EAAE;QAC9B,eAAe,EAAE,KAAK,CAAC,OAAO,CAAC,eAAe;QAC9C,MAAM,EAAE,CAAC;QACT,IAAI,EAAE,CAAC;QACP,SAAS,EAAE,MAAM;QACjB,QAAQ,EAAE,OAAO;QACjB,KAAK,EAAE,CAAC;QACR,GAAG,EAAE,CAAC;QACN,SAAS,EAAE,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,eAAe,CAAC,CAAC,CAAC,kBAAkB;QAC5D,UAAU,EAAE,sBAAsB;QAClC,MAAM,EAAE,CAAC;KACV;CACF,CAAC,CAAC;AAhBU,QAAA,cAAc,kBAgBxB;AAEH,MAAM,mBAAmB,GAAG,CAAC,KAAqB,EAAE,EAAE,CAAC,IAAA,kBAAW,EAAC,KAAK,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC;AAE7E,MAAM,SAAS,GAAG,CAAC,KAAqB,EAAE,EAAE,CAAC,CAClD,wCAAK,GAAG,EAAE,CAAC,KAAY,EAAE,EAAE,CAAC,IAAA,sBAAc,EAAC,KAAK,EAAE,KAAK,CAAC,IAAM,mBAAmB,CAAC,KAAK,CAAC,EAAI,CAC7F,CAAC;AAFW,QAAA,SAAS,aAEpB"}
1
+ {"version":3,"sources":["MenuItems.tsx"],"names":["menuItemsStyle","theme","props","alignSelf","display","justifySelf","media","QueryKeys","TABLET_DOWN","backgroundColor","general","bottom","left","overflowY","position","right","top","transform","open","transition","zIndex","filterMenuItemProps","MenuItems"],"mappings":";;;;;;;;;;;;;AAoBA;;AACA;;AAEA;;AACA;;AAxBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AAYO,IAAMA,cAAwE,GAAG,SAA3EA,cAA2E,CAACC,KAAD,EAAQC,KAAR;AAAA;AACtFC,IAAAA,SAAS,EAAE,QAD2E;AAEtFC,IAAAA,OAAO,EAAE,MAF6E;AAGtFC,IAAAA,WAAW,EAAE;AAHyE,KAIrFC,oBAAMC,wBAAUC,WAAhB,CAJqF,EAItD;AAC9BC,IAAAA,eAAe,EAAER,KAAK,CAACS,OAAN,CAAcD,eADD;AAE9BE,IAAAA,MAAM,EAAE,CAFsB;AAG9BC,IAAAA,IAAI,EAAE,CAHwB;AAI9BC,IAAAA,SAAS,EAAE,MAJmB;AAK9BC,IAAAA,QAAQ,EAAE,OALoB;AAM9BC,IAAAA,KAAK,EAAE,CANuB;AAO9BC,IAAAA,GAAG,EAAE,CAPyB;AAQ9BC,IAAAA,SAAS,EAAEf,KAAK,CAACgB,IAAN,GAAa,eAAb,GAA+B,kBARZ;AAS9BC,IAAAA,UAAU,EAAE,sBATkB;AAU9BC,IAAAA,MAAM,EAAE;AAVsB,GAJsD;AAAA,CAAjF;;;;AAkBP,IAAMC,mBAAmB,GAAG,SAAtBA,mBAAsB,CAACnB,KAAD;AAAA,SAA2B,uBAAYA,KAAZ,EAAmB,CAAC,MAAD,CAAnB,CAA3B;AAAA,CAA5B;;AAEO,IAAMoB,SAAS,GAAG,SAAZA,SAAY,CAACpB,KAAD;AAAA,SACvB;AAAK,IAAA,GAAG,EAAE,aAACD,KAAD;AAAA,aAAkBD,cAAc,CAACC,KAAD,EAAQC,KAAR,CAAhC;AAAA;AAAV,KAA8DmB,mBAAmB,CAACnB,KAAD,CAAjF,EADuB;AAAA,CAAlB","sourcesContent":["/*\n * Wire\n * Copyright (C) 2018 Wire Swiss GmbH\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program. If not, see http://www.gnu.org/licenses/.\n *\n */\n\n/** @jsx jsx */\nimport React from 'react';\nimport {CSSObject, jsx} from '@emotion/react';\n\nimport {QueryKeys, media} from '../../mediaQueries';\nimport {filterProps} from '../../util';\nimport {Theme} from '../Theme';\n\nexport interface MenuItemsProps<T = HTMLDivElement> extends React.HTMLProps<T> {\n open?: boolean;\n}\n\nexport const menuItemsStyle: <T>(theme: Theme, props: MenuItemsProps<T>) => CSSObject = (theme, props) => ({\n alignSelf: 'center',\n display: 'flex',\n justifySelf: 'end',\n [media[QueryKeys.TABLET_DOWN]]: {\n backgroundColor: theme.general.backgroundColor,\n bottom: 0,\n left: 0,\n overflowY: 'auto',\n position: 'fixed',\n right: 0,\n top: 0,\n transform: props.open ? 'translateX(0)' : 'translateX(110%)',\n transition: 'transform 0.25s ease',\n zIndex: 1,\n },\n});\n\nconst filterMenuItemProps = (props: MenuItemsProps) => filterProps(props, ['open']);\n\nexport const MenuItems = (props: MenuItemsProps) => (\n <div css={(theme: Theme) => menuItemsStyle(theme, props)} {...filterMenuItemProps(props)} />\n);\n"],"file":"MenuItems.js"}
@@ -1,72 +1,96 @@
1
1
  "use strict";
2
- /*
3
- * Wire
4
- * Copyright (C) 2018 Wire Swiss GmbH
5
- *
6
- * This program is free software: you can redistribute it and/or modify
7
- * it under the terms of the GNU General Public License as published by
8
- * the Free Software Foundation, either version 3 of the License, or
9
- * (at your option) any later version.
10
- *
11
- * This program is distributed in the hope that it will be useful,
12
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
- * GNU General Public License for more details.
15
- *
16
- * You should have received a copy of the GNU General Public License
17
- * along with this program. If not, see http://www.gnu.org/licenses/.
18
- *
19
- */
20
- var __rest = (this && this.__rest) || function (s, e) {
21
- var t = {};
22
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
23
- t[p] = s[p];
24
- if (s != null && typeof Object.getOwnPropertySymbols === "function")
25
- for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
26
- if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
27
- t[p[i]] = s[p[i]];
28
- }
29
- return t;
30
- };
31
- Object.defineProperty(exports, "__esModule", { value: true });
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
7
+ });
32
8
  exports.MenuLink = exports.filterMenuLinkProps = exports.MENU_LINK_CLASSNAME = exports.menuLinkStyle = void 0;
33
- /** @jsx jsx */
34
- const react_1 = require("@emotion/react");
35
- const mediaQueries_1 = require("../../mediaQueries");
36
- const Text_1 = require("../../Text");
37
- const util_1 = require("../../util");
38
- const HeaderSubMenu_1 = require("./HeaderSubMenu");
39
- const menuLinkStyle = (theme, _a) => {
40
- var { bold = true, color = theme.general.color, fontSize = '11px', textTransform = 'uppercase', button = false } = _a, props = __rest(_a, ["bold", "color", "fontSize", "textTransform", "button"]);
41
- return (Object.assign(Object.assign({}, (0, Text_1.linkStyle)(theme, Object.assign({ bold, color, fontSize, textTransform }, props))), { [mediaQueries_1.media[mediaQueries_1.QueryKeys.DESKTOP]]: {
42
- '&:first-of-type': {
43
- marginLeft: 0,
44
- },
45
- '&:last-of-type': {
46
- marginRight: 0,
47
- },
48
- margin: '0 26px 0 10px',
49
- [`.${HeaderSubMenu_1.DESKTOP_HEADER_SUB_MENU_CLASSNAME} &`]: {
50
- '&:first-of-type': {
51
- marginLeft: '10px',
52
- },
53
- '&:last-of-type': {
54
- marginRight: '26px',
55
- },
56
- },
57
- }, [mediaQueries_1.media[mediaQueries_1.QueryKeys.TABLET_DOWN]]: {
58
- border: 'none',
59
- fontSize: '32px !important',
60
- fontWeight: 300,
61
- maxWidth: '480px',
62
- padding: '8px 24px',
63
- textTransform: 'none !important',
64
- }, border: button ? '1px solid rgb(219, 226, 231)' : undefined, borderRadius: button ? '4px' : undefined, padding: button ? '10px 16px' : undefined }));
9
+
10
+ var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
11
+
12
+ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
13
+
14
+ var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
15
+
16
+ var _react = require("@emotion/react");
17
+
18
+ var _mediaQueries = require("../../mediaQueries");
19
+
20
+ var _Text = require("../../Text");
21
+
22
+ var _util = require("../../util");
23
+
24
+ var _HeaderSubMenu = require("./HeaderSubMenu");
25
+
26
+ var _excluded = ["bold", "color", "fontSize", "textTransform", "button"];
27
+
28
+ 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; }
29
+
30
+ 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) { (0, _defineProperty2["default"])(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; }
31
+
32
+ var menuLinkStyle = function menuLinkStyle(theme, _ref) {
33
+ var _objectSpread2;
34
+
35
+ var _ref$bold = _ref.bold,
36
+ bold = _ref$bold === void 0 ? true : _ref$bold,
37
+ _ref$color = _ref.color,
38
+ color = _ref$color === void 0 ? theme.general.color : _ref$color,
39
+ _ref$fontSize = _ref.fontSize,
40
+ fontSize = _ref$fontSize === void 0 ? '11px' : _ref$fontSize,
41
+ _ref$textTransform = _ref.textTransform,
42
+ textTransform = _ref$textTransform === void 0 ? 'uppercase' : _ref$textTransform,
43
+ _ref$button = _ref.button,
44
+ button = _ref$button === void 0 ? false : _ref$button,
45
+ props = (0, _objectWithoutProperties2["default"])(_ref, _excluded);
46
+ return _objectSpread(_objectSpread({}, (0, _Text.linkStyle)(theme, _objectSpread({
47
+ bold: bold,
48
+ color: color,
49
+ fontSize: fontSize,
50
+ textTransform: textTransform
51
+ }, props))), {}, (_objectSpread2 = {}, (0, _defineProperty2["default"])(_objectSpread2, _mediaQueries.media[_mediaQueries.QueryKeys.DESKTOP], (0, _defineProperty2["default"])({
52
+ '&:first-of-type': {
53
+ marginLeft: 0
54
+ },
55
+ '&:last-of-type': {
56
+ marginRight: 0
57
+ },
58
+ margin: '0 26px 0 10px'
59
+ }, ".".concat(_HeaderSubMenu.DESKTOP_HEADER_SUB_MENU_CLASSNAME, " &"), {
60
+ '&:first-of-type': {
61
+ marginLeft: '10px'
62
+ },
63
+ '&:last-of-type': {
64
+ marginRight: '26px'
65
+ }
66
+ })), (0, _defineProperty2["default"])(_objectSpread2, _mediaQueries.media[_mediaQueries.QueryKeys.TABLET_DOWN], {
67
+ border: 'none',
68
+ fontSize: '32px !important',
69
+ fontWeight: 300,
70
+ maxWidth: '480px',
71
+ padding: '8px 24px',
72
+ textTransform: 'none !important'
73
+ }), (0, _defineProperty2["default"])(_objectSpread2, "border", button ? '1px solid rgb(219, 226, 231)' : undefined), (0, _defineProperty2["default"])(_objectSpread2, "borderRadius", button ? '4px' : undefined), (0, _defineProperty2["default"])(_objectSpread2, "padding", button ? '10px 16px' : undefined), _objectSpread2));
65
74
  };
75
+
66
76
  exports.menuLinkStyle = menuLinkStyle;
67
- exports.MENU_LINK_CLASSNAME = 'menu-link';
68
- const filterMenuLinkProps = (props) => (0, util_1.filterProps)((0, Text_1.filterLinkProps)(props), ['button']);
77
+ var MENU_LINK_CLASSNAME = 'menu-link';
78
+ exports.MENU_LINK_CLASSNAME = MENU_LINK_CLASSNAME;
79
+
80
+ var filterMenuLinkProps = function filterMenuLinkProps(props) {
81
+ return (0, _util.filterProps)((0, _Text.filterLinkProps)(props), ['button']);
82
+ };
83
+
69
84
  exports.filterMenuLinkProps = filterMenuLinkProps;
70
- const MenuLink = (props) => ((0, react_1.jsx)("a", Object.assign({ className: exports.MENU_LINK_CLASSNAME, css: (theme) => (0, exports.menuLinkStyle)(theme, props) }, (0, exports.filterMenuLinkProps)(props))));
85
+
86
+ var MenuLink = function MenuLink(props) {
87
+ return (0, _react.jsx)("a", (0, _extends2["default"])({
88
+ className: MENU_LINK_CLASSNAME,
89
+ css: function css(theme) {
90
+ return menuLinkStyle(theme, props);
91
+ }
92
+ }, filterMenuLinkProps(props)));
93
+ };
94
+
71
95
  exports.MenuLink = MenuLink;
72
96
  //# sourceMappingURL=MenuLink.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"MenuLink.js","sourceRoot":"","sources":["MenuLink.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;GAiBG;;;;;;;;;;;;;;AAEH,eAAe;AACf,0CAA8C;AAE9C,qDAAoD;AACpD,qCAAiE;AACjE,qCAAuC;AAEvC,mDAAkE;AAM3D,MAAM,aAAa,GAA4D,CACpF,KAAK,EACL,EAAoH,EACpH,EAAE;QADF,EAAC,IAAI,GAAG,IAAI,EAAE,KAAK,GAAG,KAAK,CAAC,OAAO,CAAC,KAAK,EAAE,QAAQ,GAAG,MAAM,EAAE,aAAa,GAAG,WAAW,EAAE,MAAM,GAAG,KAAK,OAAW,EAAN,KAAK,cAAnH,wDAAoH,CAAD;IAChH,OAAA,iCACA,IAAA,gBAAS,EAAC,KAAK,kBAAG,IAAI,EAAE,KAAK,EAAE,QAAQ,EAAE,aAAa,IAAK,KAAK,EAAE,KACrE,CAAC,oBAAK,CAAC,wBAAS,CAAC,OAAO,CAAC,CAAC,EAAE;YAC1B,iBAAiB,EAAE;gBACjB,UAAU,EAAE,CAAC;aACd;YACD,gBAAgB,EAAE;gBAChB,WAAW,EAAE,CAAC;aACf;YACD,MAAM,EAAE,eAAe;YACvB,CAAC,IAAI,iDAAiC,IAAI,CAAC,EAAE;gBAC3C,iBAAiB,EAAE;oBACjB,UAAU,EAAE,MAAM;iBACnB;gBACD,gBAAgB,EAAE;oBAChB,WAAW,EAAE,MAAM;iBACpB;aACF;SACF,EACD,CAAC,oBAAK,CAAC,wBAAS,CAAC,WAAW,CAAC,CAAC,EAAE;YAC9B,MAAM,EAAE,MAAM;YACd,QAAQ,EAAE,iBAAiB;YAC3B,UAAU,EAAE,GAAG;YACf,QAAQ,EAAE,OAAO;YACjB,OAAO,EAAE,UAAU;YACnB,aAAa,EAAE,iBAAiB;SACjC,EACD,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC,8BAA8B,CAAC,CAAC,CAAC,SAAS,EAC3D,YAAY,EAAE,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,SAAS,EACxC,OAAO,EAAE,MAAM,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,SAAS,IACzC,CAAA;CAAA,CAAC;AAjCU,QAAA,aAAa,iBAiCvB;AAEU,QAAA,mBAAmB,GAAG,WAAW,CAAC;AAExC,MAAM,mBAAmB,GAAG,CAAC,KAAoB,EAAE,EAAE,CAC1D,IAAA,kBAAW,EAAC,IAAA,sBAAe,EAAC,KAAK,CAAkB,EAAE,CAAC,QAAQ,CAAC,CAAC,CAAC;AADtD,QAAA,mBAAmB,uBACmC;AAE5D,MAAM,QAAQ,GAAG,CAAC,KAAoB,EAAE,EAAE,CAAC,CAChD,sCACE,SAAS,EAAE,2BAAmB,EAC9B,GAAG,EAAE,CAAC,KAAY,EAAE,EAAE,CAAC,IAAA,qBAAa,EAAC,KAAK,EAAE,KAAK,CAAC,IAC9C,IAAA,2BAAmB,EAAC,KAAK,CAAC,EAC9B,CACH,CAAC;AANW,QAAA,QAAQ,YAMnB"}
1
+ {"version":3,"sources":["MenuLink.tsx"],"names":["menuLinkStyle","theme","bold","color","general","fontSize","textTransform","button","props","media","QueryKeys","DESKTOP","marginLeft","marginRight","margin","DESKTOP_HEADER_SUB_MENU_CLASSNAME","TABLET_DOWN","border","fontWeight","maxWidth","padding","undefined","MENU_LINK_CLASSNAME","filterMenuLinkProps","MenuLink"],"mappings":";;;;;;;;;;;;;;;AAoBA;;AAEA;;AACA;;AACA;;AAEA;;;;;;;;AAMO,IAAMA,aAAsE,GAAG,SAAzEA,aAAyE,CACpFC,KADoF;AAAA;;AAAA,uBAEnFC,IAFmF;AAAA,MAEnFA,IAFmF,0BAE5E,IAF4E;AAAA,wBAEtEC,KAFsE;AAAA,MAEtEA,KAFsE,2BAE9DF,KAAK,CAACG,OAAN,CAAcD,KAFgD;AAAA,2BAEzCE,QAFyC;AAAA,MAEzCA,QAFyC,8BAE9B,MAF8B;AAAA,gCAEtBC,aAFsB;AAAA,MAEtBA,aAFsB,mCAEN,WAFM;AAAA,yBAEOC,MAFP;AAAA,MAEOA,MAFP,4BAEgB,KAFhB;AAAA,MAE0BC,KAF1B;AAAA,yCAIjF,qBAAUP,KAAV;AAAkBC,IAAAA,IAAI,EAAJA,IAAlB;AAAwBC,IAAAA,KAAK,EAALA,KAAxB;AAA+BE,IAAAA,QAAQ,EAARA,QAA/B;AAAyCC,IAAAA,aAAa,EAAbA;AAAzC,KAA2DE,KAA3D,EAJiF,8EAKnFC,oBAAMC,wBAAUC,OAAhB,CALmF;AAMlF,uBAAmB;AACjBC,MAAAA,UAAU,EAAE;AADK,KAN+D;AASlF,sBAAkB;AAChBC,MAAAA,WAAW,EAAE;AADG,KATgE;AAYlFC,IAAAA,MAAM,EAAE;AAZ0E,gBAa7EC,gDAb6E,SAarC;AAC3C,uBAAmB;AACjBH,MAAAA,UAAU,EAAE;AADK,KADwB;AAI3C,sBAAkB;AAChBC,MAAAA,WAAW,EAAE;AADG;AAJyB,GAbqC,qDAsBnFJ,oBAAMC,wBAAUM,WAAhB,CAtBmF,EAsBpD;AAC9BC,IAAAA,MAAM,EAAE,MADsB;AAE9BZ,IAAAA,QAAQ,EAAE,iBAFoB;AAG9Ba,IAAAA,UAAU,EAAE,GAHkB;AAI9BC,IAAAA,QAAQ,EAAE,OAJoB;AAK9BC,IAAAA,OAAO,EAAE,UALqB;AAM9Bd,IAAAA,aAAa,EAAE;AANe,GAtBoD,8DA8B5EC,MAAM,GAAG,8BAAH,GAAoCc,SA9BkC,oEA+BtEd,MAAM,GAAG,KAAH,GAAWc,SA/BqD,+DAgC3Ed,MAAM,GAAG,WAAH,GAAiBc,SAhCoD;AAAA,CAA/E;;;AAmCA,IAAMC,mBAAmB,GAAG,WAA5B;;;AAEA,IAAMC,mBAAmB,GAAG,SAAtBA,mBAAsB,CAACf,KAAD;AAAA,SACjC,uBAAY,2BAAgBA,KAAhB,CAAZ,EAAqD,CAAC,QAAD,CAArD,CADiC;AAAA,CAA5B;;;;AAGA,IAAMgB,QAAQ,GAAG,SAAXA,QAAW,CAAChB,KAAD;AAAA,SACtB;AACE,IAAA,SAAS,EAAEc,mBADb;AAEE,IAAA,GAAG,EAAE,aAACrB,KAAD;AAAA,aAAkBD,aAAa,CAACC,KAAD,EAAQO,KAAR,CAA/B;AAAA;AAFP,KAGMe,mBAAmB,CAACf,KAAD,CAHzB,EADsB;AAAA,CAAjB","sourcesContent":["/*\n * Wire\n * Copyright (C) 2018 Wire Swiss GmbH\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program. If not, see http://www.gnu.org/licenses/.\n *\n */\n\n/** @jsx jsx */\nimport {CSSObject, jsx} from '@emotion/react';\n\nimport {QueryKeys, media} from '../../mediaQueries';\nimport {LinkProps, filterLinkProps, linkStyle} from '../../Text';\nimport {filterProps} from '../../util';\nimport {Theme} from '../Theme';\nimport {DESKTOP_HEADER_SUB_MENU_CLASSNAME} from './HeaderSubMenu';\n\nexport interface MenuLinkProps<T = HTMLAnchorElement> extends LinkProps<T> {\n button?: boolean;\n}\n\nexport const menuLinkStyle: <T>(theme: Theme, props: MenuLinkProps<T>) => CSSObject = (\n theme,\n {bold = true, color = theme.general.color, fontSize = '11px', textTransform = 'uppercase', button = false, ...props},\n) => ({\n ...linkStyle(theme, {bold, color, fontSize, textTransform, ...props}),\n [media[QueryKeys.DESKTOP]]: {\n '&:first-of-type': {\n marginLeft: 0,\n },\n '&:last-of-type': {\n marginRight: 0,\n },\n margin: '0 26px 0 10px',\n [`.${DESKTOP_HEADER_SUB_MENU_CLASSNAME} &`]: {\n '&:first-of-type': {\n marginLeft: '10px',\n },\n '&:last-of-type': {\n marginRight: '26px',\n },\n },\n },\n [media[QueryKeys.TABLET_DOWN]]: {\n border: 'none',\n fontSize: '32px !important',\n fontWeight: 300,\n maxWidth: '480px',\n padding: '8px 24px',\n textTransform: 'none !important',\n },\n border: button ? '1px solid rgb(219, 226, 231)' : undefined,\n borderRadius: button ? '4px' : undefined,\n padding: button ? '10px 16px' : undefined,\n});\n\nexport const MENU_LINK_CLASSNAME = 'menu-link';\n\nexport const filterMenuLinkProps = (props: MenuLinkProps) =>\n filterProps(filterLinkProps(props) as MenuLinkProps, ['button']);\n\nexport const MenuLink = (props: MenuLinkProps) => (\n <a\n className={MENU_LINK_CLASSNAME}\n css={(theme: Theme) => menuLinkStyle(theme, props)}\n {...filterMenuLinkProps(props)}\n />\n);\n"],"file":"MenuLink.js"}
@@ -1,4 +1,24 @@
1
1
  "use strict";
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
7
+ });
8
+ exports.MenuOpenButton = exports.menuOpenButtonStyle = void 0;
9
+
10
+ var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
11
+
12
+ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
13
+
14
+ var _react = require("@emotion/react");
15
+
16
+ var _react2 = _interopRequireDefault(require("react"));
17
+
18
+ var _mediaQueries = require("../../mediaQueries");
19
+
20
+ var _util = require("../../util");
21
+
2
22
  /*
3
23
  * Wire
4
24
  * Copyright (C) 2018 Wire Swiss GmbH
@@ -17,41 +37,49 @@
17
37
  * along with this program. If not, see http://www.gnu.org/licenses/.
18
38
  *
19
39
  */
20
- Object.defineProperty(exports, "__esModule", { value: true });
21
- exports.MenuOpenButton = exports.menuOpenButtonStyle = void 0;
40
+
22
41
  /** @jsx jsx */
23
- const react_1 = require("@emotion/react");
24
- const mediaQueries_1 = require("../../mediaQueries");
25
- const util_1 = require("../../util");
26
- const menuOpenButtonStyle = (theme, { open }) => ({
42
+ var menuOpenButtonStyle = function menuOpenButtonStyle(theme, _ref) {
43
+ var _ref2;
44
+
45
+ var open = _ref.open;
46
+ return _ref2 = {
27
47
  display: 'block',
28
48
  div: {
29
- backgroundColor: theme.general.color,
30
- height: '2px',
31
- margin: '4px',
32
- transition: 'all 0.25s ease-in-out',
33
- width: '16px',
49
+ backgroundColor: theme.general.color,
50
+ height: '2px',
51
+ margin: '4px',
52
+ transition: 'all 0.25s ease-in-out',
53
+ width: '16px'
34
54
  },
35
55
  'div:nth-of-type(1)': {
36
- transform: open ? 'translateY(6px) rotate(-45deg)' : undefined,
56
+ transform: open ? 'translateY(6px) rotate(-45deg)' : undefined
37
57
  },
38
58
  'div:nth-of-type(2)': {
39
- opacity: open ? 0 : undefined,
40
- transform: open ? 'scale(0, 1)' : undefined,
59
+ opacity: open ? 0 : undefined,
60
+ transform: open ? 'scale(0, 1)' : undefined
41
61
  },
42
62
  'div:nth-of-type(3)': {
43
- transform: open ? 'translateY(-6px) rotate(45deg)' : undefined,
44
- },
45
- [mediaQueries_1.media[mediaQueries_1.QueryKeys.DESKTOP]]: {
46
- display: 'none',
47
- },
48
- zIndex: 2,
49
- });
63
+ transform: open ? 'translateY(-6px) rotate(45deg)' : undefined
64
+ }
65
+ }, (0, _defineProperty2["default"])(_ref2, _mediaQueries.media[_mediaQueries.QueryKeys.DESKTOP], {
66
+ display: 'none'
67
+ }), (0, _defineProperty2["default"])(_ref2, "zIndex", 2), _ref2;
68
+ };
69
+
50
70
  exports.menuOpenButtonStyle = menuOpenButtonStyle;
51
- const filterMenuOpenButtonProps = (props) => (0, util_1.filterProps)(props, ['open']);
52
- const MenuOpenButton = (props) => ((0, react_1.jsx)("div", Object.assign({ css: (theme) => (0, exports.menuOpenButtonStyle)(theme, props) }, filterMenuOpenButtonProps(props)),
53
- (0, react_1.jsx)("div", null),
54
- (0, react_1.jsx)("div", null),
55
- (0, react_1.jsx)("div", null)));
71
+
72
+ var filterMenuOpenButtonProps = function filterMenuOpenButtonProps(props) {
73
+ return (0, _util.filterProps)(props, ['open']);
74
+ };
75
+
76
+ var MenuOpenButton = function MenuOpenButton(props) {
77
+ return (0, _react.jsx)("div", (0, _extends2["default"])({
78
+ css: function css(theme) {
79
+ return menuOpenButtonStyle(theme, props);
80
+ }
81
+ }, filterMenuOpenButtonProps(props)), (0, _react.jsx)("div", null), (0, _react.jsx)("div", null), (0, _react.jsx)("div", null));
82
+ };
83
+
56
84
  exports.MenuOpenButton = MenuOpenButton;
57
85
  //# sourceMappingURL=MenuOpenButton.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"MenuOpenButton.js","sourceRoot":"","sources":["MenuOpenButton.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;GAiBG;;;AAEH,eAAe;AACf,0CAA8C;AAG9C,qDAAoD;AACpD,qCAAuC;AAOhC,MAAM,mBAAmB,GAAkE,CAAC,KAAK,EAAE,EAAC,IAAI,EAAC,EAAE,EAAE,CAAC,CAAC;IACpH,OAAO,EAAE,OAAO;IAChB,GAAG,EAAE;QACH,eAAe,EAAE,KAAK,CAAC,OAAO,CAAC,KAAK;QACpC,MAAM,EAAE,KAAK;QACb,MAAM,EAAE,KAAK;QACb,UAAU,EAAE,uBAAuB;QACnC,KAAK,EAAE,MAAM;KACd;IACD,oBAAoB,EAAE;QACpB,SAAS,EAAE,IAAI,CAAC,CAAC,CAAC,gCAAgC,CAAC,CAAC,CAAC,SAAS;KAC/D;IACD,oBAAoB,EAAE;QACpB,OAAO,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,SAAS;QAC7B,SAAS,EAAE,IAAI,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,SAAS;KAC5C;IACD,oBAAoB,EAAE;QACpB,SAAS,EAAE,IAAI,CAAC,CAAC,CAAC,gCAAgC,CAAC,CAAC,CAAC,SAAS;KAC/D;IACD,CAAC,oBAAK,CAAC,wBAAS,CAAC,OAAO,CAAC,CAAC,EAAE;QAC1B,OAAO,EAAE,MAAM;KAChB;IACD,MAAM,EAAE,CAAC;CACV,CAAC,CAAC;AAvBU,QAAA,mBAAmB,uBAuB7B;AAEH,MAAM,yBAAyB,GAAG,CAAC,KAA0B,EAAE,EAAE,CAAC,IAAA,kBAAW,EAAC,KAAK,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC;AAExF,MAAM,cAAc,GAAG,CAAC,KAA0B,EAAE,EAAE,CAAC,CAC5D,wCAAK,GAAG,EAAE,CAAC,KAAY,EAAE,EAAE,CAAC,IAAA,2BAAmB,EAAC,KAAK,EAAE,KAAK,CAAC,IAAM,yBAAyB,CAAC,KAAK,CAAC;IACjG,6BAAO;IACP,6BAAO;IACP,6BAAO,CACH,CACP,CAAC;AANW,QAAA,cAAc,kBAMzB"}
1
+ {"version":3,"sources":["MenuOpenButton.tsx"],"names":["menuOpenButtonStyle","theme","open","display","div","backgroundColor","general","color","height","margin","transition","width","transform","undefined","opacity","media","QueryKeys","DESKTOP","filterMenuOpenButtonProps","props","MenuOpenButton"],"mappings":";;;;;;;;;;;;;AAoBA;;AACA;;AAEA;;AACA;;AAxBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AAYO,IAAMA,mBAAkF,GAAG,SAArFA,mBAAqF,CAACC,KAAD;AAAA;;AAAA,MAASC,IAAT,QAASA,IAAT;AAAA;AAChGC,IAAAA,OAAO,EAAE,OADuF;AAEhGC,IAAAA,GAAG,EAAE;AACHC,MAAAA,eAAe,EAAEJ,KAAK,CAACK,OAAN,CAAcC,KAD5B;AAEHC,MAAAA,MAAM,EAAE,KAFL;AAGHC,MAAAA,MAAM,EAAE,KAHL;AAIHC,MAAAA,UAAU,EAAE,uBAJT;AAKHC,MAAAA,KAAK,EAAE;AALJ,KAF2F;AAShG,0BAAsB;AACpBC,MAAAA,SAAS,EAAEV,IAAI,GAAG,gCAAH,GAAsCW;AADjC,KAT0E;AAYhG,0BAAsB;AACpBC,MAAAA,OAAO,EAAEZ,IAAI,GAAG,CAAH,GAAOW,SADA;AAEpBD,MAAAA,SAAS,EAAEV,IAAI,GAAG,aAAH,GAAmBW;AAFd,KAZ0E;AAgBhG,0BAAsB;AACpBD,MAAAA,SAAS,EAAEV,IAAI,GAAG,gCAAH,GAAsCW;AADjC;AAhB0E,6CAmB/FE,oBAAMC,wBAAUC,OAAhB,CAnB+F,EAmBpE;AAC1Bd,IAAAA,OAAO,EAAE;AADiB,GAnBoE,qDAsBxF,CAtBwF;AAAA,CAA3F;;;;AAyBP,IAAMe,yBAAyB,GAAG,SAA5BA,yBAA4B,CAACC,KAAD;AAAA,SAAgC,uBAAYA,KAAZ,EAAmB,CAAC,MAAD,CAAnB,CAAhC;AAAA,CAAlC;;AAEO,IAAMC,cAAc,GAAG,SAAjBA,cAAiB,CAACD,KAAD;AAAA,SAC5B;AAAK,IAAA,GAAG,EAAE,aAAClB,KAAD;AAAA,aAAkBD,mBAAmB,CAACC,KAAD,EAAQkB,KAAR,CAArC;AAAA;AAAV,KAAmED,yBAAyB,CAACC,KAAD,CAA5F,GACE,4BADF,EAEE,4BAFF,EAGE,4BAHF,CAD4B;AAAA,CAAvB","sourcesContent":["/*\n * Wire\n * Copyright (C) 2018 Wire Swiss GmbH\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program. If not, see http://www.gnu.org/licenses/.\n *\n */\n\n/** @jsx jsx */\nimport {CSSObject, jsx} from '@emotion/react';\nimport React from 'react';\n\nimport {QueryKeys, media} from '../../mediaQueries';\nimport {filterProps} from '../../util';\nimport {Theme} from '../Theme';\n\nexport interface MenuOpenButtonProps<T = HTMLDivElement> extends React.HTMLProps<T> {\n open?: boolean;\n}\n\nexport const menuOpenButtonStyle: <T>(theme: Theme, props: MenuOpenButtonProps<T>) => CSSObject = (theme, {open}) => ({\n display: 'block',\n div: {\n backgroundColor: theme.general.color,\n height: '2px',\n margin: '4px',\n transition: 'all 0.25s ease-in-out',\n width: '16px',\n },\n 'div:nth-of-type(1)': {\n transform: open ? 'translateY(6px) rotate(-45deg)' : undefined,\n },\n 'div:nth-of-type(2)': {\n opacity: open ? 0 : undefined,\n transform: open ? 'scale(0, 1)' : undefined,\n },\n 'div:nth-of-type(3)': {\n transform: open ? 'translateY(-6px) rotate(45deg)' : undefined,\n },\n [media[QueryKeys.DESKTOP]]: {\n display: 'none',\n },\n zIndex: 2,\n});\n\nconst filterMenuOpenButtonProps = (props: MenuOpenButtonProps) => filterProps(props, ['open']);\n\nexport const MenuOpenButton = (props: MenuOpenButtonProps) => (\n <div css={(theme: Theme) => menuOpenButtonStyle(theme, props)} {...filterMenuOpenButtonProps(props)}>\n <div />\n <div />\n <div />\n </div>\n);\n"],"file":"MenuOpenButton.js"}
@@ -1,4 +1,22 @@
1
1
  "use strict";
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
7
+ });
8
+ exports.MenuScrollableItems = exports.menuScrollableItemsStyle = void 0;
9
+
10
+ var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
11
+
12
+ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
13
+
14
+ var _react = require("@emotion/react");
15
+
16
+ var _react2 = _interopRequireDefault(require("react"));
17
+
18
+ var _mediaQueries = require("../../mediaQueries");
19
+
2
20
  /*
3
21
  * Wire
4
22
  * Copyright (C) 2018 Wire Swiss GmbH
@@ -17,22 +35,27 @@
17
35
  * along with this program. If not, see http://www.gnu.org/licenses/.
18
36
  *
19
37
  */
20
- Object.defineProperty(exports, "__esModule", { value: true });
21
- exports.MenuScrollableItems = exports.menuScrollableItemsStyle = void 0;
38
+
22
39
  /** @jsx jsx */
23
- const react_1 = require("@emotion/react");
24
- const mediaQueries_1 = require("../../mediaQueries");
25
- const menuScrollableItemsStyle = props => ({
40
+ var menuScrollableItemsStyle = function menuScrollableItemsStyle(props) {
41
+ return (0, _defineProperty2["default"])({
26
42
  alignItems: 'center',
27
43
  alignSelf: 'center',
28
- display: 'flex',
29
- [mediaQueries_1.media[mediaQueries_1.QueryKeys.TABLET_DOWN]]: {
30
- alignItems: 'center',
31
- flexDirection: 'column',
32
- margin: 'auto',
33
- },
34
- });
44
+ display: 'flex'
45
+ }, _mediaQueries.media[_mediaQueries.QueryKeys.TABLET_DOWN], {
46
+ alignItems: 'center',
47
+ flexDirection: 'column',
48
+ margin: 'auto'
49
+ });
50
+ };
51
+
35
52
  exports.menuScrollableItemsStyle = menuScrollableItemsStyle;
36
- const MenuScrollableItems = (props) => ((0, react_1.jsx)("div", Object.assign({ css: (0, exports.menuScrollableItemsStyle)(props) }, props)));
53
+
54
+ var MenuScrollableItems = function MenuScrollableItems(props) {
55
+ return (0, _react.jsx)("div", (0, _extends2["default"])({
56
+ css: menuScrollableItemsStyle(props)
57
+ }, props));
58
+ };
59
+
37
60
  exports.MenuScrollableItems = MenuScrollableItems;
38
61
  //# sourceMappingURL=MenuScrollableItems.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"MenuScrollableItems.js","sourceRoot":"","sources":["MenuScrollableItems.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;GAiBG;;;AAEH,eAAe;AACf,0CAA8C;AAG9C,qDAAoD;AAM7C,MAAM,wBAAwB,GAAyD,KAAK,CAAC,EAAE,CAAC,CAAC;IACtG,UAAU,EAAE,QAAQ;IACpB,SAAS,EAAE,QAAQ;IACnB,OAAO,EAAE,MAAM;IACf,CAAC,oBAAK,CAAC,wBAAS,CAAC,WAAW,CAAC,CAAC,EAAE;QAC9B,UAAU,EAAE,QAAQ;QACpB,aAAa,EAAE,QAAQ;QACvB,MAAM,EAAE,MAAM;KACf;CACF,CAAC,CAAC;AATU,QAAA,wBAAwB,4BASlC;AAEI,MAAM,mBAAmB,GAAG,CAAC,KAA+B,EAAE,EAAE,CAAC,CACtE,wCAAK,GAAG,EAAE,IAAA,gCAAwB,EAAC,KAAK,CAAC,IAAM,KAAK,EAAI,CACzD,CAAC;AAFW,QAAA,mBAAmB,uBAE9B"}
1
+ {"version":3,"sources":["MenuScrollableItems.tsx"],"names":["menuScrollableItemsStyle","props","alignItems","alignSelf","display","media","QueryKeys","TABLET_DOWN","flexDirection","margin","MenuScrollableItems"],"mappings":";;;;;;;;;;;;;AAoBA;;AACA;;AAEA;;AAvBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AAUO,IAAMA,wBAA8E,GAAG,SAAjFA,wBAAiF,CAAAC,KAAK;AAAA;AACjGC,IAAAA,UAAU,EAAE,QADqF;AAEjGC,IAAAA,SAAS,EAAE,QAFsF;AAGjGC,IAAAA,OAAO,EAAE;AAHwF,KAIhGC,oBAAMC,wBAAUC,WAAhB,CAJgG,EAIjE;AAC9BL,IAAAA,UAAU,EAAE,QADkB;AAE9BM,IAAAA,aAAa,EAAE,QAFe;AAG9BC,IAAAA,MAAM,EAAE;AAHsB,GAJiE;AAAA,CAA5F;;;;AAWA,IAAMC,mBAAmB,GAAG,SAAtBA,mBAAsB,CAACT,KAAD;AAAA,SACjC;AAAK,IAAA,GAAG,EAAED,wBAAwB,CAACC,KAAD;AAAlC,KAA+CA,KAA/C,EADiC;AAAA,CAA5B","sourcesContent":["/*\n * Wire\n * Copyright (C) 2018 Wire Swiss GmbH\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program. If not, see http://www.gnu.org/licenses/.\n *\n */\n\n/** @jsx jsx */\nimport {CSSObject, jsx} from '@emotion/react';\nimport React from 'react';\n\nimport {QueryKeys, media} from '../../mediaQueries';\n\nexport interface MenuScrollableItemsProps<T = HTMLDivElement> extends React.HTMLProps<T> {\n open?: boolean;\n}\n\nexport const menuScrollableItemsStyle: <T>(props: MenuScrollableItemsProps<T>) => CSSObject = props => ({\n alignItems: 'center',\n alignSelf: 'center',\n display: 'flex',\n [media[QueryKeys.TABLET_DOWN]]: {\n alignItems: 'center',\n flexDirection: 'column',\n margin: 'auto',\n },\n});\n\nexport const MenuScrollableItems = (props: MenuScrollableItemsProps) => (\n <div css={menuScrollableItemsStyle(props)} {...props} />\n);\n"],"file":"MenuScrollableItems.js"}
@@ -1,50 +1,69 @@
1
1
  "use strict";
2
- /*
3
- * Wire
4
- * Copyright (C) 2018 Wire Swiss GmbH
5
- *
6
- * This program is free software: you can redistribute it and/or modify
7
- * it under the terms of the GNU General Public License as published by
8
- * the Free Software Foundation, either version 3 of the License, or
9
- * (at your option) any later version.
10
- *
11
- * This program is distributed in the hope that it will be useful,
12
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
- * GNU General Public License for more details.
15
- *
16
- * You should have received a copy of the GNU General Public License
17
- * along with this program. If not, see http://www.gnu.org/licenses/.
18
- *
19
- */
20
- Object.defineProperty(exports, "__esModule", { value: true });
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
7
+ });
21
8
  exports.MenuSubLink = exports.menuSubLinkStyle = void 0;
22
- /** @jsx jsx */
23
- const react_1 = require("@emotion/react");
24
- const motions_1 = require("../../Identity/motions");
25
- const mediaQueries_1 = require("../../mediaQueries");
26
- const Text_1 = require("../../Text");
27
- const menuSubLinkStyle = (theme, props) => (Object.assign(Object.assign({}, (0, Text_1.textStyle)(theme, props)), { '&:hover': {
28
- filter: 'brightness(70%)',
29
- }, color: theme.general.color, cursor: 'pointer', fontWeight: 600, textDecoration: 'none', transition: motions_1.defaultTransition, [mediaQueries_1.media[mediaQueries_1.QueryKeys.DESKTOP]]: {
30
- '&:first-of-type': {
31
- marginLeft: 0,
32
- },
33
- '&:last-child': {
34
- marginRight: 0,
35
- },
36
- fontSize: '11px',
37
- margin: '0 26px 0 10px',
38
- textTransform: 'uppercase',
39
- }, [mediaQueries_1.media[mediaQueries_1.QueryKeys.TABLET_DOWN]]: {
40
- border: 'none',
41
- fontSize: '32px !important',
42
- fontWeight: '300 !important',
43
- maxWidth: '480px',
44
- padding: '8px 24px',
45
- textTransform: 'none !important',
46
- } }));
9
+
10
+ var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
11
+
12
+ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
13
+
14
+ var _react = require("@emotion/react");
15
+
16
+ var _motions = require("../../Identity/motions");
17
+
18
+ var _mediaQueries = require("../../mediaQueries");
19
+
20
+ var _Text = require("../../Text");
21
+
22
+ 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; }
23
+
24
+ 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) { (0, _defineProperty2["default"])(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; }
25
+
26
+ var menuSubLinkStyle = function menuSubLinkStyle(theme, props) {
27
+ var _objectSpread2;
28
+
29
+ return _objectSpread(_objectSpread({}, (0, _Text.textStyle)(theme, props)), {}, (_objectSpread2 = {
30
+ '&:hover': {
31
+ filter: 'brightness(70%)'
32
+ },
33
+ color: theme.general.color,
34
+ cursor: 'pointer',
35
+ fontWeight: 600,
36
+ textDecoration: 'none',
37
+ transition: _motions.defaultTransition
38
+ }, (0, _defineProperty2["default"])(_objectSpread2, _mediaQueries.media[_mediaQueries.QueryKeys.DESKTOP], {
39
+ '&:first-of-type': {
40
+ marginLeft: 0
41
+ },
42
+ '&:last-child': {
43
+ marginRight: 0
44
+ },
45
+ fontSize: '11px',
46
+ margin: '0 26px 0 10px',
47
+ textTransform: 'uppercase'
48
+ }), (0, _defineProperty2["default"])(_objectSpread2, _mediaQueries.media[_mediaQueries.QueryKeys.TABLET_DOWN], {
49
+ border: 'none',
50
+ fontSize: '32px !important',
51
+ fontWeight: '300 !important',
52
+ maxWidth: '480px',
53
+ padding: '8px 24px',
54
+ textTransform: 'none !important'
55
+ }), _objectSpread2));
56
+ };
57
+
47
58
  exports.menuSubLinkStyle = menuSubLinkStyle;
48
- const MenuSubLink = (props) => ((0, react_1.jsx)("div", Object.assign({ css: (theme) => (0, exports.menuSubLinkStyle)(theme, props) }, props)));
59
+
60
+ var MenuSubLink = function MenuSubLink(props) {
61
+ return (0, _react.jsx)("div", (0, _extends2["default"])({
62
+ css: function css(theme) {
63
+ return menuSubLinkStyle(theme, props);
64
+ }
65
+ }, props));
66
+ };
67
+
49
68
  exports.MenuSubLink = MenuSubLink;
50
69
  //# sourceMappingURL=MenuSubLink.js.map