@laerdal/life-react-components 1.2.2-dev.7 → 1.2.2-dev.8

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 (303) hide show
  1. package/dist/esm/Banners/Banner.js +1 -0
  2. package/dist/esm/Banners/Banner.js.map +1 -1
  3. package/dist/esm/Breadcrumb/Breadcrumb.js.map +1 -1
  4. package/dist/esm/Button/BackButton.js +4 -4
  5. package/dist/esm/Button/BackButton.js.map +1 -1
  6. package/dist/esm/Button/__tests__/BackButton.test.js +3 -4
  7. package/dist/esm/Button/__tests__/BackButton.test.js.map +1 -1
  8. package/dist/esm/Chips/ActionChip.js +2 -3
  9. package/dist/esm/Chips/ActionChip.js.map +1 -1
  10. package/dist/esm/Chips/ChipInput.js +1 -2
  11. package/dist/esm/Chips/ChipInput.js.map +1 -1
  12. package/dist/esm/Chips/FilterChip.js +2 -3
  13. package/dist/esm/Chips/FilterChip.js.map +1 -1
  14. package/dist/esm/Chips/InputChip.js +2 -3
  15. package/dist/esm/Chips/InputChip.js.map +1 -1
  16. package/dist/esm/Dropdown/BasicDropdown.js +3 -2
  17. package/dist/esm/Dropdown/BasicDropdown.js.map +1 -1
  18. package/dist/esm/Dropdown/ChipDropdownInput.js +2 -3
  19. package/dist/esm/Dropdown/ChipDropdownInput.js.map +1 -1
  20. package/dist/esm/Dropdown/CommonStyling.js +2 -1
  21. package/dist/esm/Dropdown/CommonStyling.js.map +1 -1
  22. package/dist/esm/Dropdown/DropdownContent.js +13 -1
  23. package/dist/esm/Dropdown/DropdownContent.js.map +1 -1
  24. package/dist/esm/Dropdown/DropdownFilter.js +4 -3
  25. package/dist/esm/Dropdown/DropdownFilter.js.map +1 -1
  26. package/dist/esm/GlobalNavigationBar/ExtendedMainMenu.js +3 -3
  27. package/dist/esm/GlobalNavigationBar/ExtendedMainMenu.js.map +1 -1
  28. package/dist/esm/GlobalNavigationBar/GlobalNavigationBar.js +6 -2
  29. package/dist/esm/GlobalNavigationBar/GlobalNavigationBar.js.map +1 -1
  30. package/dist/esm/GlobalNavigationBar/UserMenu/MobileUserMenu.js +2 -1
  31. package/dist/esm/GlobalNavigationBar/UserMenu/MobileUserMenu.js.map +1 -1
  32. package/dist/esm/GlobalNavigationBar/UserMenu/UserMenu.js +2 -1
  33. package/dist/esm/GlobalNavigationBar/UserMenu/UserMenu.js.map +1 -1
  34. package/dist/esm/GlobalNavigationBar/mobile/CommonStyles.js +8 -1
  35. package/dist/esm/GlobalNavigationBar/mobile/CommonStyles.js.map +1 -1
  36. package/dist/esm/InputFields/DatepickerField.js +6 -0
  37. package/dist/esm/InputFields/DatepickerField.js.map +1 -1
  38. package/dist/esm/InputFields/Label.js +2 -1
  39. package/dist/esm/InputFields/Label.js.map +1 -1
  40. package/dist/esm/InputFields/PasswordField.js +2 -1
  41. package/dist/esm/InputFields/PasswordField.js.map +1 -1
  42. package/dist/esm/InputFields/QuickSearch.js +2 -2
  43. package/dist/esm/InputFields/QuickSearch.js.map +1 -1
  44. package/dist/esm/InputFields/ResponsiveComponentWrapper.js +2 -2
  45. package/dist/esm/InputFields/ResponsiveComponentWrapper.js.map +1 -1
  46. package/dist/esm/InputFields/SearchBar.js +1 -0
  47. package/dist/esm/InputFields/SearchBar.js.map +1 -1
  48. package/dist/esm/InputFields/TextField.js +1 -0
  49. package/dist/esm/InputFields/TextField.js.map +1 -1
  50. package/dist/esm/InputFields/Textarea.js +2 -1
  51. package/dist/esm/InputFields/Textarea.js.map +1 -1
  52. package/dist/esm/InputFields/__tests__/QuickSearch.test.js +1 -2
  53. package/dist/esm/InputFields/__tests__/QuickSearch.test.js.map +1 -1
  54. package/dist/esm/InputFields/components/SearchBarInput.js +1 -0
  55. package/dist/esm/InputFields/components/SearchBarInput.js.map +1 -1
  56. package/dist/esm/List/ListRow.js +4 -1
  57. package/dist/esm/List/ListRow.js.map +1 -1
  58. package/dist/esm/LoadingIndicator/LoadingIndicator.js +4 -4
  59. package/dist/esm/LoadingIndicator/LoadingIndicator.js.map +1 -1
  60. package/dist/esm/Modals/ModalContainer.js +3 -1
  61. package/dist/esm/Modals/ModalContainer.js.map +1 -1
  62. package/dist/esm/NavItem/NavItem.js +4 -0
  63. package/dist/esm/NavItem/NavItem.js.map +1 -1
  64. package/dist/esm/NotificationDot/NotificationDot.js +9 -9
  65. package/dist/esm/NotificationDot/NotificationDot.js.map +1 -1
  66. package/dist/esm/NotificationDot/__tests__/NotificationDot.test.js +2 -3
  67. package/dist/esm/NotificationDot/__tests__/NotificationDot.test.js.map +1 -1
  68. package/dist/esm/Paginator/Paginator.js +5 -0
  69. package/dist/esm/Paginator/Paginator.js.map +1 -1
  70. package/dist/esm/Switcher/MobileSwitcherMenu.js +2 -1
  71. package/dist/esm/Switcher/MobileSwitcherMenu.js.map +1 -1
  72. package/dist/esm/Switcher/SwitcherMenuItem.js +5 -0
  73. package/dist/esm/Switcher/SwitcherMenuItem.js.map +1 -1
  74. package/dist/esm/Table/Table.js +1 -1
  75. package/dist/esm/Table/Table.js.map +1 -1
  76. package/dist/esm/Tabs/HorizontalTabs.js +15 -9
  77. package/dist/esm/Tabs/HorizontalTabs.js.map +1 -1
  78. package/dist/esm/Tabs/TabLink.js +17 -6
  79. package/dist/esm/Tabs/TabLink.js.map +1 -1
  80. package/dist/esm/Tabs/Tabs.js +14 -14
  81. package/dist/esm/Tabs/Tabs.js.map +1 -1
  82. package/dist/esm/Tabs/VerticalTabs.js +2 -2
  83. package/dist/esm/Tabs/VerticalTabs.js.map +1 -1
  84. package/dist/esm/Toasters/ToastContext.js +2 -1
  85. package/dist/esm/Toasters/ToastContext.js.map +1 -1
  86. package/dist/esm/Tooltips/TooltipStyles.js +3 -2
  87. package/dist/esm/Tooltips/TooltipStyles.js.map +1 -1
  88. package/dist/esm/styles/typography.js +8 -9
  89. package/dist/esm/styles/typography.js.map +1 -1
  90. package/dist/esm/styles/z-indexes.js +14 -0
  91. package/dist/esm/styles/z-indexes.js.map +1 -0
  92. package/dist/esm/types.js +0 -1
  93. package/dist/esm/types.js.map +1 -1
  94. package/dist/js/Banners/Banner.d.ts +1 -2
  95. package/dist/js/Banners/Banner.js +1 -0
  96. package/dist/js/Banners/Banner.js.map +1 -1
  97. package/dist/js/Breadcrumb/Breadcrumb.js.map +1 -1
  98. package/dist/js/Button/BackButton.d.ts +1 -2
  99. package/dist/js/Button/BackButton.js +4 -5
  100. package/dist/js/Button/BackButton.js.map +1 -1
  101. package/dist/js/Button/__tests__/BackButton.test.js +3 -5
  102. package/dist/js/Button/__tests__/BackButton.test.js.map +1 -1
  103. package/dist/js/Chips/ActionChip.js +2 -4
  104. package/dist/js/Chips/ActionChip.js.map +1 -1
  105. package/dist/js/Chips/ChipInput.js +1 -3
  106. package/dist/js/Chips/ChipInput.js.map +1 -1
  107. package/dist/js/Chips/ChipTypes.d.ts +3 -3
  108. package/dist/js/Chips/FilterChip.js +2 -4
  109. package/dist/js/Chips/FilterChip.js.map +1 -1
  110. package/dist/js/Chips/InputChip.js +2 -4
  111. package/dist/js/Chips/InputChip.js.map +1 -1
  112. package/dist/js/Dropdown/BasicDropdown.d.ts +1 -2
  113. package/dist/js/Dropdown/BasicDropdown.js +3 -2
  114. package/dist/js/Dropdown/BasicDropdown.js.map +1 -1
  115. package/dist/js/Dropdown/ChipDropdownInput.d.ts +3 -0
  116. package/dist/js/Dropdown/ChipDropdownInput.js +2 -4
  117. package/dist/js/Dropdown/ChipDropdownInput.js.map +1 -1
  118. package/dist/js/Dropdown/CommonStyling.js +3 -1
  119. package/dist/js/Dropdown/CommonStyling.js.map +1 -1
  120. package/dist/js/Dropdown/DropdownContent.js +5 -3
  121. package/dist/js/Dropdown/DropdownContent.js.map +1 -1
  122. package/dist/js/Dropdown/DropdownFilter.d.ts +1 -2
  123. package/dist/js/Dropdown/DropdownFilter.js +4 -3
  124. package/dist/js/Dropdown/DropdownFilter.js.map +1 -1
  125. package/dist/js/GlobalNavigationBar/ExtendedMainMenu.js +3 -3
  126. package/dist/js/GlobalNavigationBar/ExtendedMainMenu.js.map +1 -1
  127. package/dist/js/GlobalNavigationBar/GlobalNavigationBar.js +5 -3
  128. package/dist/js/GlobalNavigationBar/GlobalNavigationBar.js.map +1 -1
  129. package/dist/js/GlobalNavigationBar/UserMenu/MobileUserMenu.js +3 -1
  130. package/dist/js/GlobalNavigationBar/UserMenu/MobileUserMenu.js.map +1 -1
  131. package/dist/js/GlobalNavigationBar/UserMenu/UserMenu.js +3 -1
  132. package/dist/js/GlobalNavigationBar/UserMenu/UserMenu.js.map +1 -1
  133. package/dist/js/GlobalNavigationBar/mobile/CommonStyles.js +4 -2
  134. package/dist/js/GlobalNavigationBar/mobile/CommonStyles.js.map +1 -1
  135. package/dist/js/InputFields/DatepickerField.js +3 -1
  136. package/dist/js/InputFields/DatepickerField.js.map +1 -1
  137. package/dist/js/InputFields/Label.d.ts +1 -2
  138. package/dist/js/InputFields/Label.js +1 -0
  139. package/dist/js/InputFields/Label.js.map +1 -1
  140. package/dist/js/InputFields/PasswordField.d.ts +1 -2
  141. package/dist/js/InputFields/PasswordField.js +2 -1
  142. package/dist/js/InputFields/PasswordField.js.map +1 -1
  143. package/dist/js/InputFields/QuickSearch.d.ts +1 -2
  144. package/dist/js/InputFields/QuickSearch.js +2 -3
  145. package/dist/js/InputFields/QuickSearch.js.map +1 -1
  146. package/dist/js/InputFields/ResponsiveComponentWrapper.d.ts +1 -2
  147. package/dist/js/InputFields/ResponsiveComponentWrapper.js +2 -3
  148. package/dist/js/InputFields/ResponsiveComponentWrapper.js.map +1 -1
  149. package/dist/js/InputFields/SearchBar.d.ts +1 -2
  150. package/dist/js/InputFields/SearchBar.js +1 -0
  151. package/dist/js/InputFields/SearchBar.js.map +1 -1
  152. package/dist/js/InputFields/TextField.d.ts +1 -2
  153. package/dist/js/InputFields/TextField.js +1 -0
  154. package/dist/js/InputFields/TextField.js.map +1 -1
  155. package/dist/js/InputFields/Textarea.d.ts +1 -2
  156. package/dist/js/InputFields/Textarea.js +1 -0
  157. package/dist/js/InputFields/Textarea.js.map +1 -1
  158. package/dist/js/InputFields/__tests__/QuickSearch.test.js +1 -3
  159. package/dist/js/InputFields/__tests__/QuickSearch.test.js.map +1 -1
  160. package/dist/js/InputFields/components/SearchBarInput.d.ts +1 -2
  161. package/dist/js/InputFields/components/SearchBarInput.js +1 -0
  162. package/dist/js/InputFields/components/SearchBarInput.js.map +1 -1
  163. package/dist/js/List/ListRow.js +3 -1
  164. package/dist/js/List/ListRow.js.map +1 -1
  165. package/dist/js/LoadingIndicator/LoadingIndicator.d.ts +1 -2
  166. package/dist/js/LoadingIndicator/LoadingIndicator.js +4 -5
  167. package/dist/js/LoadingIndicator/LoadingIndicator.js.map +1 -1
  168. package/dist/js/Modals/ModalContainer.js +3 -1
  169. package/dist/js/Modals/ModalContainer.js.map +1 -1
  170. package/dist/js/NavItem/NavItem.js +3 -1
  171. package/dist/js/NavItem/NavItem.js.map +1 -1
  172. package/dist/js/NotificationDot/NotificationDot.d.ts +1 -2
  173. package/dist/js/NotificationDot/NotificationDot.js +9 -10
  174. package/dist/js/NotificationDot/NotificationDot.js.map +1 -1
  175. package/dist/js/NotificationDot/__tests__/NotificationDot.test.js +2 -4
  176. package/dist/js/NotificationDot/__tests__/NotificationDot.test.js.map +1 -1
  177. package/dist/js/Paginator/Paginator.js +3 -1
  178. package/dist/js/Paginator/Paginator.js.map +1 -1
  179. package/dist/js/Switcher/MobileSwitcherMenu.js +3 -1
  180. package/dist/js/Switcher/MobileSwitcherMenu.js.map +1 -1
  181. package/dist/js/Switcher/SwitcherMenuItem.js +3 -1
  182. package/dist/js/Switcher/SwitcherMenuItem.js.map +1 -1
  183. package/dist/js/Table/Table.js +1 -1
  184. package/dist/js/Table/Table.js.map +1 -1
  185. package/dist/js/Tabs/HorizontalTabs.d.ts +2 -2
  186. package/dist/js/Tabs/HorizontalTabs.js +5 -4
  187. package/dist/js/Tabs/HorizontalTabs.js.map +1 -1
  188. package/dist/js/Tabs/TabLink.d.ts +1 -2
  189. package/dist/js/Tabs/TabLink.js +6 -5
  190. package/dist/js/Tabs/TabLink.js.map +1 -1
  191. package/dist/js/Tabs/Tabs.d.ts +1 -2
  192. package/dist/js/Tabs/Tabs.js +14 -15
  193. package/dist/js/Tabs/Tabs.js.map +1 -1
  194. package/dist/js/Tabs/VerticalTabs.d.ts +1 -2
  195. package/dist/js/Tabs/VerticalTabs.js +2 -3
  196. package/dist/js/Tabs/VerticalTabs.js.map +1 -1
  197. package/dist/js/Toasters/ToastContext.js +3 -1
  198. package/dist/js/Toasters/ToastContext.js.map +1 -1
  199. package/dist/js/Tooltips/TooltipStyles.js +4 -2
  200. package/dist/js/Tooltips/TooltipStyles.js.map +1 -1
  201. package/dist/js/styles/typography.d.ts +1 -2
  202. package/dist/js/styles/typography.js +8 -10
  203. package/dist/js/styles/typography.js.map +1 -1
  204. package/dist/js/styles/z-indexes.d.ts +13 -0
  205. package/dist/js/styles/z-indexes.js +21 -0
  206. package/dist/js/styles/z-indexes.js.map +1 -0
  207. package/dist/js/types.d.ts +0 -1
  208. package/dist/js/types.js +0 -1
  209. package/dist/js/types.js.map +1 -1
  210. package/dist/umd/Banners/Banner.js +1 -0
  211. package/dist/umd/Banners/Banner.js.map +1 -1
  212. package/dist/umd/Breadcrumb/Breadcrumb.js.map +1 -1
  213. package/dist/umd/Button/BackButton.js +8 -7
  214. package/dist/umd/Button/BackButton.js.map +1 -1
  215. package/dist/umd/Button/__tests__/BackButton.test.js +7 -7
  216. package/dist/umd/Button/__tests__/BackButton.test.js.map +1 -1
  217. package/dist/umd/Chips/ActionChip.js +6 -6
  218. package/dist/umd/Chips/ActionChip.js.map +1 -1
  219. package/dist/umd/Chips/ChipInput.js +5 -5
  220. package/dist/umd/Chips/ChipInput.js.map +1 -1
  221. package/dist/umd/Chips/FilterChip.js +6 -6
  222. package/dist/umd/Chips/FilterChip.js.map +1 -1
  223. package/dist/umd/Chips/InputChip.js +6 -6
  224. package/dist/umd/Chips/InputChip.js.map +1 -1
  225. package/dist/umd/Dropdown/BasicDropdown.js +3 -2
  226. package/dist/umd/Dropdown/BasicDropdown.js.map +1 -1
  227. package/dist/umd/Dropdown/ChipDropdownInput.js +6 -6
  228. package/dist/umd/Dropdown/ChipDropdownInput.js.map +1 -1
  229. package/dist/umd/Dropdown/CommonStyling.js +5 -5
  230. package/dist/umd/Dropdown/CommonStyling.js.map +1 -1
  231. package/dist/umd/Dropdown/DropdownContent.js +16 -5
  232. package/dist/umd/Dropdown/DropdownContent.js.map +1 -1
  233. package/dist/umd/Dropdown/DropdownFilter.js +4 -3
  234. package/dist/umd/Dropdown/DropdownFilter.js.map +1 -1
  235. package/dist/umd/GlobalNavigationBar/ExtendedMainMenu.js +6 -6
  236. package/dist/umd/GlobalNavigationBar/ExtendedMainMenu.js.map +1 -1
  237. package/dist/umd/GlobalNavigationBar/GlobalNavigationBar.js +9 -6
  238. package/dist/umd/GlobalNavigationBar/GlobalNavigationBar.js.map +1 -1
  239. package/dist/umd/GlobalNavigationBar/UserMenu/MobileUserMenu.js +5 -5
  240. package/dist/umd/GlobalNavigationBar/UserMenu/MobileUserMenu.js.map +1 -1
  241. package/dist/umd/GlobalNavigationBar/UserMenu/UserMenu.js +5 -5
  242. package/dist/umd/GlobalNavigationBar/UserMenu/UserMenu.js.map +1 -1
  243. package/dist/umd/GlobalNavigationBar/mobile/CommonStyles.js +11 -5
  244. package/dist/umd/GlobalNavigationBar/mobile/CommonStyles.js.map +1 -1
  245. package/dist/umd/InputFields/DatepickerField.js +9 -4
  246. package/dist/umd/InputFields/DatepickerField.js.map +1 -1
  247. package/dist/umd/InputFields/Label.js +1 -0
  248. package/dist/umd/InputFields/Label.js.map +1 -1
  249. package/dist/umd/InputFields/PasswordField.js +2 -1
  250. package/dist/umd/InputFields/PasswordField.js.map +1 -1
  251. package/dist/umd/InputFields/QuickSearch.js +6 -5
  252. package/dist/umd/InputFields/QuickSearch.js.map +1 -1
  253. package/dist/umd/InputFields/ResponsiveComponentWrapper.js +6 -5
  254. package/dist/umd/InputFields/ResponsiveComponentWrapper.js.map +1 -1
  255. package/dist/umd/InputFields/SearchBar.js +1 -0
  256. package/dist/umd/InputFields/SearchBar.js.map +1 -1
  257. package/dist/umd/InputFields/TextField.js +1 -0
  258. package/dist/umd/InputFields/TextField.js.map +1 -1
  259. package/dist/umd/InputFields/Textarea.js +1 -0
  260. package/dist/umd/InputFields/Textarea.js.map +1 -1
  261. package/dist/umd/InputFields/__tests__/QuickSearch.test.js +5 -5
  262. package/dist/umd/InputFields/__tests__/QuickSearch.test.js.map +1 -1
  263. package/dist/umd/InputFields/components/SearchBarInput.js +1 -0
  264. package/dist/umd/InputFields/components/SearchBarInput.js.map +1 -1
  265. package/dist/umd/List/ListRow.js +7 -5
  266. package/dist/umd/List/ListRow.js.map +1 -1
  267. package/dist/umd/LoadingIndicator/LoadingIndicator.js +8 -7
  268. package/dist/umd/LoadingIndicator/LoadingIndicator.js.map +1 -1
  269. package/dist/umd/Modals/ModalContainer.js +6 -5
  270. package/dist/umd/Modals/ModalContainer.js.map +1 -1
  271. package/dist/umd/NavItem/NavItem.js +7 -4
  272. package/dist/umd/NavItem/NavItem.js.map +1 -1
  273. package/dist/umd/NotificationDot/NotificationDot.js +13 -12
  274. package/dist/umd/NotificationDot/NotificationDot.js.map +1 -1
  275. package/dist/umd/NotificationDot/__tests__/NotificationDot.test.js +6 -6
  276. package/dist/umd/NotificationDot/__tests__/NotificationDot.test.js.map +1 -1
  277. package/dist/umd/Paginator/Paginator.js +8 -4
  278. package/dist/umd/Paginator/Paginator.js.map +1 -1
  279. package/dist/umd/Switcher/MobileSwitcherMenu.js +5 -5
  280. package/dist/umd/Switcher/MobileSwitcherMenu.js.map +1 -1
  281. package/dist/umd/Switcher/SwitcherMenuItem.js +8 -4
  282. package/dist/umd/Switcher/SwitcherMenuItem.js.map +1 -1
  283. package/dist/umd/Table/Table.js +1 -1
  284. package/dist/umd/Table/Table.js.map +1 -1
  285. package/dist/umd/Tabs/HorizontalTabs.js +17 -11
  286. package/dist/umd/Tabs/HorizontalTabs.js.map +1 -1
  287. package/dist/umd/Tabs/TabLink.js +20 -9
  288. package/dist/umd/Tabs/TabLink.js.map +1 -1
  289. package/dist/umd/Tabs/Tabs.js +18 -17
  290. package/dist/umd/Tabs/Tabs.js.map +1 -1
  291. package/dist/umd/Tabs/VerticalTabs.js +6 -5
  292. package/dist/umd/Tabs/VerticalTabs.js.map +1 -1
  293. package/dist/umd/Toasters/ToastContext.js +5 -5
  294. package/dist/umd/Toasters/ToastContext.js.map +1 -1
  295. package/dist/umd/Tooltips/TooltipStyles.js +6 -6
  296. package/dist/umd/Tooltips/TooltipStyles.js.map +1 -1
  297. package/dist/umd/styles/typography.js +12 -12
  298. package/dist/umd/styles/typography.js.map +1 -1
  299. package/dist/umd/styles/z-indexes.js +33 -0
  300. package/dist/umd/styles/z-indexes.js.map +1 -0
  301. package/dist/umd/types.js +0 -1
  302. package/dist/umd/types.js.map +1 -1
  303. package/package.json +1 -1
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../src/InputFields/components/SearchBarInput.tsx"],"names":["React","styled","BREAKPOINTS","COLORS","ComponentTextStyle","ComponentMStyling","ComponentSStyling","Search","input","attrs","type","Regular","black","Italic","neutral_500","BigSearch","neutral_600","MEDIUM","SearchBarInput","forwardRef","props","ref","id","searchTerm","setSearchTerm","enterSearch","placeholder","disabled","onKeyDown","size","setTabbedHere","onBlur","isPressingEnter","e","key","preventDefault","stopPropagation","target","value"],"mappings":";AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,OAAOC,MAAP,MAAmB,mBAAnB;AACA,SAASC,WAAT,EAAsBC,MAAtB,EAA8BC,kBAA9B,QAAwD,oBAAxD;AAEA,SAASC,iBAAT,EAA4BC,iBAA5B,QAAqD,yBAArD;AAEA,OAAO,MAAMC,MAAM,GAAGN,MAAM,CAACO,KAAP,CAAaC,KAAb,CAAmB,OAAO;AAAEC,EAAAA,IAAI,EAAE;AAAR,CAAP,CAAnB,CAA+C;AACrE;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AAAqGC,IAAAA;AAArG,MAAgHX,KAAtH;;AACA,QAAMY,eAAe,GAAIC,CAAD,IAAY;AAClC,QAAIA,CAAC,CAACC,GAAF,KAAU,OAAd,EAAuB;AACrBD,MAAAA,CAAC,CAACE,cAAF;AACAF,MAAAA,CAAC,CAACG,eAAF;AACA,aAAO,IAAP;AACD;;AACD,WAAO,KAAP;AACD,GAPD;;AASA,sBACE,oBAAC,SAAD;AACE,IAAA,WAAW,EAAET,QAAQ,GAAG,EAAH,GAAQD,WAD/B;AAEE,IAAA,EAAE,EAAEJ,EAFN;AAGE,mBAAaA,EAHf;AAIE,IAAA,SAAS,EAAEO,IAAI,GAAGA,IAAH,GAAU,EAJ3B;AAKE,IAAA,QAAQ,EAAE,CALZ;AAME,IAAA,QAAQ,EAAEF,QANZ;AAOE,IAAA,QAAQ,EAAGM,CAAD,IAAYT,aAAa,CAACS,CAAC,CAACI,MAAF,CAASC,KAAV,CAPrC;AAQE,IAAA,KAAK,EAAEf,UART;AASE,IAAA,GAAG,EAAEF,GATP;AAUE,IAAA,MAAM,EAAGY,CAAD,IAAQF,MAAM,GAAGA,MAAM,CAACE,CAAD,CAAT,GAAeH,aAAa,CAAC,KAAD,CAVpD;AAWE,IAAA,SAAS,EAAEF,SAXb;AAYE,IAAA,UAAU,EAAGK,CAAD,IAAaD,eAAe,CAACC,CAAD,CAAf,GAAqBR,WAAW,CAACQ,CAAD,CAAhC,GAAsC;AAZjE,IADF;AAgBD,CA3BsB,CAAvB;;AAZEX,EAAAA,E;AACAC,EAAAA,U;AACAC,EAAAA,a;AACAC,EAAAA,W;AACAC,EAAAA,W;AACAC,EAAAA,Q;AACAC,EAAAA,S;AAEAE,EAAAA,a;AACAC,EAAAA,M;;AAgCF,eAAeb,cAAf","sourcesContent":["import * as React from 'react';\nimport styled from 'styled-components';\nimport { BREAKPOINTS, COLORS, ComponentTextStyle } from '../../styles/index';\nimport { Size } from '../../types';\nimport { ComponentMStyling, ComponentSStyling } from '../../styles/typography';\n\nexport const Search = styled.input.attrs(() => ({ type: 'search' }))`\n appearance: none;\n width: calc(100% - 96px);\n ${ComponentSStyling(ComponentTextStyle.Regular, COLORS.black)}\n\n /* To prevent browser putting its own cross inside the search bar */\n ::-ms-clear {\n display: none;\n width: 0;\n height: 0;\n }\n ::-ms-reveal {\n display: none;\n width: 0;\n height: 0;\n }\n ::-webkit-search-decoration,\n ::-webkit-search-cancel-button,\n ::-webkit-search-results-button,\n ::-webkit-search-results-decoration {\n display: none;\n }\n\n ::placeholder {\n ${ComponentSStyling(ComponentTextStyle.Italic, COLORS.neutral_500)}\n }\n\n &:focus {\n outline-width: 0;\n }\n`;\n\nexport const BigSearch = styled(Search)`\n height: 32px;\n border-width: 0;\n margin-left: 50px;\n outline: none;\n\n ${ComponentMStyling(ComponentTextStyle.Regular, COLORS.black)}\n\n ::placeholder {\n ${ComponentSStyling(ComponentTextStyle.Italic, COLORS.neutral_600)}\n }\n ${BREAKPOINTS.MEDIUM} {\n ::placeholder {\n ${ComponentMStyling(ComponentTextStyle.Italic, COLORS.neutral_600)}\n }\n }\n &.small {\n ::placeholder {\n ${ComponentSStyling(ComponentTextStyle.Italic, COLORS.neutral_600)}\n }\n }\n &.medium {\n ::placeholder {\n ${ComponentMStyling(ComponentTextStyle.Italic, COLORS.neutral_600)}\n }\n }\n &:disabled {\n background: transparent;\n border: none;\n }\n`;\n\ntype SearchBarInputProps = {\n id: string;\n searchTerm?: string;\n setSearchTerm: (term: string) => void;\n enterSearch: (e: any) => void;\n placeholder?: string;\n disabled?: boolean;\n onKeyDown?: (e: React.KeyboardEvent) => void;\n size?: Size.Small | Size.Medium;\n setTabbedHere: (tabbedHere: boolean) => void;\n onBlur?: (e: any) => void;\n};\n\nconst SearchBarInput = React.forwardRef<HTMLInputElement, SearchBarInputProps>((props: SearchBarInputProps, ref) => {\n const { id, searchTerm, setSearchTerm, enterSearch, placeholder, disabled, onKeyDown, size, setTabbedHere, onBlur } = props;\n const isPressingEnter = (e: any) => {\n if (e.key === 'Enter') {\n e.preventDefault();\n e.stopPropagation();\n return true;\n }\n return false;\n };\n\n return (\n <BigSearch\n placeholder={disabled ? '' : placeholder}\n id={id}\n data-testid={id}\n className={size ? size : ''}\n tabIndex={0}\n disabled={disabled}\n onChange={(e: any) => setSearchTerm(e.target.value)}\n value={searchTerm}\n ref={ref}\n onBlur={(e) => (onBlur ? onBlur(e) : setTabbedHere(false))}\n onKeyDown={onKeyDown}\n onKeyPress={(e: any) => (isPressingEnter(e) ? enterSearch(e) : null)}\n />\n );\n});\n\nexport default SearchBarInput;\n"],"file":"SearchBarInput.js"}
1
+ {"version":3,"sources":["../../../../src/InputFields/components/SearchBarInput.tsx"],"names":["React","styled","BREAKPOINTS","COLORS","ComponentTextStyle","ComponentMStyling","ComponentSStyling","Search","input","attrs","type","Regular","black","Italic","neutral_500","BigSearch","neutral_600","MEDIUM","SearchBarInput","forwardRef","props","ref","id","searchTerm","setSearchTerm","enterSearch","placeholder","disabled","onKeyDown","size","setTabbedHere","onBlur","isPressingEnter","e","key","preventDefault","stopPropagation","target","value"],"mappings":";AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,OAAOC,MAAP,MAAmB,mBAAnB;AACA,SAASC,WAAT,EAAsBC,MAAtB,EAA8BC,kBAA9B,QAAwD,oBAAxD;AACA,SAASC,iBAAT,EAA4BC,iBAA5B,QAAqD,yBAArD;AAEA,OAAO,MAAMC,MAAM,GAAGN,MAAM,CAACO,KAAP,CAAaC,KAAb,CAAmB,OAAO;AAAEC,EAAAA,IAAI,EAAE;AAAR,CAAP,CAAnB,CAA+C;AACrE;AACA;AACA,IAAIJ,iBAAiB,CAACF,kBAAkB,CAACO,OAApB,EAA6BR,MAAM,CAACS,KAApC,CAA2C;AAChE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMN,iBAAiB,CAACF,kBAAkB,CAACS,MAApB,EAA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GAPD;;AASA,sBACE,oBAAC,SAAD;AACE,IAAA,WAAW,EAAET,QAAQ,GAAG,EAAH,GAAQD,WAD/B;AAEE,IAAA,EAAE,EAAEJ,EAFN;AAGE,mBAAaA,EAHf;AAIE,IAAA,SAAS,EAAEO,IAAI,GAAGA,IAAH,GAAU,EAJ3B;AAKE,IAAA,QAAQ,EAAE,CALZ;AAME,IAAA,QAAQ,EAAEF,QANZ;AAOE,IAAA,QAAQ,EAAGM,CAAD,IAAYT,aAAa,CAACS,CAAC,CAACI,MAAF,CAASC,KAAV,CAPrC;AAQE,IAAA,KAAK,EAAEf,UART;AASE,IAAA,GAAG,EAAEF,GATP;AAUE,IAAA,MAAM,EAAGY,CAAD,IAAQF,MAAM,GAAGA,MAAM,CAACE,CAAD,CAAT,GAAeH,aAAa,CAAC,KAAD,CAVpD;AAWE,IAAA,SAAS,EAAEF,SAXb;AAYE,IAAA,UAAU,EAAGK,CAAD,IAAaD,eAAe,CAACC,CAAD,CAAf,GAAqBR,WAAW,CAACQ,CAAD,CAAhC,GAAsC;AAZjE,IADF;AAgBD,CA3BsB,CAAvB;;AAZEX,EAAAA,E;AACAC,EAAAA,U;AACAC,EAAAA,a;AACAC,EAAAA,W;AACAC,EAAAA,W;AACAC,EAAAA,Q;AACAC,EAAAA,S;AACAC,EAAAA,I,aAAO,O,EAAU,Q;AACjBC,EAAAA,a;AACAC,EAAAA,M;;AAgCF,eAAeb,cAAf","sourcesContent":["import * as React from 'react';\nimport styled from 'styled-components';\nimport { BREAKPOINTS, COLORS, ComponentTextStyle } from '../../styles/index';\nimport { ComponentMStyling, ComponentSStyling } from '../../styles/typography';\n\nexport const Search = styled.input.attrs(() => ({ type: 'search' }))`\n appearance: none;\n width: calc(100% - 96px);\n ${ComponentSStyling(ComponentTextStyle.Regular, COLORS.black)}\n\n /* To prevent browser putting its own cross inside the search bar */\n ::-ms-clear {\n display: none;\n width: 0;\n height: 0;\n }\n ::-ms-reveal {\n display: none;\n width: 0;\n height: 0;\n }\n ::-webkit-search-decoration,\n ::-webkit-search-cancel-button,\n ::-webkit-search-results-button,\n ::-webkit-search-results-decoration {\n display: none;\n }\n\n ::placeholder {\n ${ComponentSStyling(ComponentTextStyle.Italic, COLORS.neutral_500)}\n }\n\n &:focus {\n outline-width: 0;\n }\n`;\n\nexport const BigSearch = styled(Search)`\n height: 32px;\n border-width: 0;\n margin-left: 50px;\n outline: none;\n\n ${ComponentMStyling(ComponentTextStyle.Regular, COLORS.black)}\n\n ::placeholder {\n ${ComponentSStyling(ComponentTextStyle.Italic, COLORS.neutral_600)}\n }\n ${BREAKPOINTS.MEDIUM} {\n ::placeholder {\n ${ComponentMStyling(ComponentTextStyle.Italic, COLORS.neutral_600)}\n }\n }\n &.small {\n ::placeholder {\n ${ComponentSStyling(ComponentTextStyle.Italic, COLORS.neutral_600)}\n }\n }\n &.medium {\n ::placeholder {\n ${ComponentMStyling(ComponentTextStyle.Italic, COLORS.neutral_600)}\n }\n }\n &:disabled {\n background: transparent;\n border: none;\n }\n`;\n\ntype SearchBarInputProps = {\n id: string;\n searchTerm?: string;\n setSearchTerm: (term: string) => void;\n enterSearch: (e: any) => void;\n placeholder?: string;\n disabled?: boolean;\n onKeyDown?: (e: React.KeyboardEvent) => void;\n size?: 'small' | 'medium';\n setTabbedHere: (tabbedHere: boolean) => void;\n onBlur?: (e: any) => void;\n};\n\nconst SearchBarInput = React.forwardRef<HTMLInputElement, SearchBarInputProps>((props: SearchBarInputProps, ref) => {\n const { id, searchTerm, setSearchTerm, enterSearch, placeholder, disabled, onKeyDown, size, setTabbedHere, onBlur } = props;\n const isPressingEnter = (e: any) => {\n if (e.key === 'Enter') {\n e.preventDefault();\n e.stopPropagation();\n return true;\n }\n return false;\n };\n\n return (\n <BigSearch\n placeholder={disabled ? '' : placeholder}\n id={id}\n data-testid={id}\n className={size ? size : ''}\n tabIndex={0}\n disabled={disabled}\n onChange={(e: any) => setSearchTerm(e.target.value)}\n value={searchTerm}\n ref={ref}\n onBlur={(e) => (onBlur ? onBlur(e) : setTabbedHere(false))}\n onKeyDown={onKeyDown}\n onKeyPress={(e: any) => (isPressingEnter(e) ? enterSearch(e) : null)}\n />\n );\n});\n\nexport default SearchBarInput;\n"],"file":"SearchBarInput.js"}
@@ -10,6 +10,7 @@ import { TooltipWrapper } from '../Tooltips';
10
10
  import { DropdownButton } from '../Dropdown';
11
11
  import { SystemIcons } from '../icons';
12
12
  import { Size } from '../types';
13
+ import { Z_INDEXES } from '../styles/z-indexes';
13
14
  const Row = styled.div`
14
15
  display: flex;
15
16
  flex-direction: row;
@@ -36,18 +37,20 @@ const Row = styled.div`
36
37
  &.interactive:hover:not(.in-action):not(.disabled) {
37
38
  background-color: ${COLORS.primary_20};
38
39
  color: ${COLORS.primary_700};
40
+ z-index: ${Z_INDEXES.hover};
39
41
  }
40
42
 
41
43
  &.interactive:active:not(.in-action):not(.disabled) {
42
44
  background-color: ${COLORS.primary_100};
43
45
  color: ${COLORS.primary_800};
44
46
  box-shadow: none;
47
+ z-index: ${Z_INDEXES.active};
45
48
  }
46
49
 
47
50
  &.interactive:focus {
48
51
  outline: none;
49
52
  box-shadow: 0 4px 12px rgba(46, 127, 161, 0.25), 0 0 8px #2E7FA1;
50
- z-index: 1;
53
+ z-index: ${Z_INDEXES.focus};
51
54
  }
52
55
 
53
56
  &.disabled {
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/List/ListRow.tsx"],"names":["React","styled","COLORS","ComponentTextStyle","ComponentLStyling","ComponentMStyling","ComponentSStyling","ComponentXSStyling","ComponentXXSStyling","TooltipWrapper","DropdownButton","SystemIcons","Size","Row","div","neutral_100","neutral_600","white","primary_20","primary_700","primary_100","primary_800","neutral_300","Regular","ListRow","size","Medium","variant","icon","mainText","secondaryText","dropdown","note","noteTooltip","disabled","action","inAction","setInAction","useState","handleKeyPress","e","key","rowClassName","concat","undefined","Large","Small","XSmall"],"mappings":";;;;AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,OAAOC,MAAP,MAAmB,mBAAnB;AACA,SAAQC,MAAR,EAAgBC,kBAAhB,QAAyC,WAAzC;AAEA,SACEC,iBADF,EAEEC,iBAFF,EAGEC,iBAHF,EAIEC,kBAJF,EAKEC,mBALF,QAMO,sBANP;AAQA,SAAQC,cAAR,QAA6B,aAA7B;AACA,SAAQC,cAAR,QAA6B,aAA7B;AACA,SAAQC,WAAR,QAA0B,UAA1B;AACA,SAAQC,IAAR,QAAmB,UAAnB;AAEA,MAAMC,GAAG,GAAGZ,MAAM,CAACa,GAAI;AACvB;AACA;AACA;AACA;AACA,6BAA6BZ,MAAM,CAACa,WAAY;AAChD;AACA;AACA;AACA,WAAWb,MAAM,CAACc,WAAY;AAC9B,sBAAsBd,MAAM,CAACe,KAAM;AACnC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,wBAAwBf,MAAM,CAACgB,UAAW;AAC1C,aAAahB,MAAM,CAACiB,WAAY;AAChC;AACA;AACA;AACA,wBAAwBjB,MAAM,CAACkB,WAAY;AAC3C,aAAalB,MAAM,CAACmB,WAAY;AAChC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAenB,MAAM,CAACoB,WAAY;AAClC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQhB,iBAAiB,CAACH,kBAAkB,CAACoB,OAApB,EAA6B,IAA7B,CAAmC;AAC5D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQlB,iBAAiB,CAACF,kBAAkB,CAACoB,OAApB,EAA6B,IAA7B,CAAmC;AAC5D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQnB,iBAAiB,CAACD,kBAAkB,CAACoB,OAApB,EAA6B,IAA7B,CAAmC;AAC5D;AACA;AACA;AACA;AACA;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AAAK,IAAA,SAAS,EAAE,mBAAhB;AACK,IAAA,YAAY,EAAE,MAAMM,WAAW,CAAC,CAACN,QAAQ,EAAEG,QAAZ,CADpC;AAEK,IAAA,YAAY,EAAE,MAAMG,WAAW,CAAC,KAAD;AAFpC,kBAGE,oBAAC,cAAD,eAAoBN,QAApB;AACgB,IAAA,QAAQ,EAAEG,QAAQ,IAAIH,QAAQ,CAACG,QAD/C;AAEgB,IAAA,IAAI,EAAEP,OAAO,KAAK,SAAZ,gBACF,oBAAC,WAAD,CAAa,aAAb,OADE,gBAEF,oBAAC,WAAD,CAAa,YAAb;AAJpB,KAHF,CAvCJ,CADF;AAqDD,CAjFD;;;AAXEA,EAAAA,O,aAAU,Q,EAAW,S;AACrBC,EAAAA,I;AACAC,EAAAA,Q;AACAC,EAAAA,a;AAEAE,EAAAA,I;AACAC,EAAAA,W;AACAC,EAAAA,Q;AACAC,EAAAA,M;;AAsFF,eAAeX,OAAf","sourcesContent":["import * as React from 'react';\nimport styled from 'styled-components';\nimport {COLORS, ComponentTextStyle} from '../styles';\n\nimport {\n ComponentLStyling,\n ComponentMStyling,\n ComponentSStyling,\n ComponentXSStyling,\n ComponentXXSStyling\n} from '../styles/typography';\nimport {DropdownButtonProps} from '../Dropdown/DropdownButtonTypes';\nimport {TooltipWrapper} from '../Tooltips';\nimport {DropdownButton} from '../Dropdown';\nimport {SystemIcons} from '../icons';\nimport {Size} from '../types';\n\nconst Row = styled.div`\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: center;\n border-bottom: 1px solid ${COLORS.neutral_100};\n box-sizing: border-box;\n position: relative;\n\n color: ${COLORS.neutral_600};\n background-color: ${COLORS.white};\n\n\n cursor: default;\n\n &.interactive {\n cursor: pointer;\n }\n\n &.interactive.disabled {\n cursor: not-allowed;\n }\n\n &.interactive:hover:not(.in-action):not(.disabled) {\n background-color: ${COLORS.primary_20};\n color: ${COLORS.primary_700};\n }\n\n &.interactive:active:not(.in-action):not(.disabled) {\n background-color: ${COLORS.primary_100};\n color: ${COLORS.primary_800};\n box-shadow: none;\n }\n\n &.interactive:focus {\n outline: none;\n box-shadow: 0 4px 12px rgba(46, 127, 161, 0.25), 0 0 8px #2E7FA1;\n z-index: 1;\n }\n\n &.disabled {\n .list-item-icon, .list-item-content, .list-item-note, .list-item-actions {\n color: ${COLORS.neutral_300};\n }\n }\n\n\n &.small {\n min-height: 48px;\n padding: 0 8px;\n\n .list-item-icon {\n margin-right: 8px;\n }\n\n .list-item-main-text {\n ${ComponentSStyling(ComponentTextStyle.Regular, null)}\n }\n\n .list-item-actions {\n margin-right: -8px;\n }\n }\n\n &.medium {\n min-height: 56px;\n padding: 0 12px;\n\n .list-item-icon {\n margin-right: 12px;\n }\n\n .list-item-main-text {\n ${ComponentMStyling(ComponentTextStyle.Regular, null)}\n }\n\n .list-item-actions {\n margin-right: -12px;\n }\n }\n\n &.large {\n min-height: 64px;\n padding: 0 16px;\n\n .list-item-icon {\n margin-right: 16px;\n }\n\n .list-item-main-text {\n ${ComponentLStyling(ComponentTextStyle.Regular, null)}\n }\n\n .list-item-actions {\n margin-right: -16px;\n }\n }\n\n &.overlay {\n padding: 0 4px;\n\n .list-item-actions {\n margin-right: -4px;\n }\n }\n\n .list-item-icon {\n width: 24px;\n height: 24px;\n\n svg {\n width: 24px;\n height: 24px;\n }\n }\n\n .list-item-content {\n flex-grow: 1;\n display: flex;\n flex-direction: column;\n }\n\n .list-item-main-text {\n }\n\n .list-item-secondary-text {\n ${ComponentXXSStyling(ComponentTextStyle.Regular, null)}\n }\n\n .list-item-note {\n color: ${COLORS.neutral_600};\n word-break: initial;\n ${ComponentXSStyling(ComponentTextStyle.Regular, null)}\n }\n\n .list-item-note.with-tooltip {\n cursor: pointer;\n\n > div {\n text-decoration-line: underline;\n text-decoration-style: dashed;\n text-underline-offset: 1px;\n text-decoration-thickness: 1px;\n }\n }\n\n .list-item-actions {\n color: ${COLORS.neutral_600};\n display: flex;\n align-items: center;\n\n button div {\n background-color: transparent;\n }\n }\n`;\n\n\ntype Props = {\n size?: Size;\n variant?: 'normal' | 'overlay';\n icon?: React.ReactNode;\n mainText: string;\n secondaryText?: string;\n dropdown?: Pick<DropdownButtonProps, 'items' | 'onClick' | 'disabled' | 'width'>;\n note?: string;\n noteTooltip?: string;\n disabled?: boolean;\n action?: () => void;\n};\n\nconst ListRow: React.FunctionComponent<Props> = ({\n size = Size.Medium,\n variant = 'normal',\n icon,\n mainText,\n secondaryText,\n dropdown,\n note,\n noteTooltip,\n disabled = false,\n action\n }: Props) => {\n\n const [inAction, setInAction] = React.useState<Boolean>(false);\n\n const handleKeyPress = (e: any) => {\n if (e.key === 'Enter') {\n action && action()\n }\n }\n\n const rowClassName = (inAction ? 'in-action ' : '')\n .concat(disabled ? 'disabled ' : '')\n .concat(!!action ? 'interactive ' : '')\n .concat('list-item-row ')\n .concat(`${variant} `)\n .concat(`${size}`);\n\n return (\n <Row tabIndex={!!action && !disabled ? 0 : undefined}\n className={rowClassName}\n onKeyPress={(e) => !disabled && handleKeyPress(e)}\n onClick={e => {\n !disabled && action && action();\n }}\n data-hj-suppress>\n {\n !!icon &&\n <div className={'list-item-icon'}>{icon}</div>\n }\n <div className={'list-item-content'}>\n <div className={'list-item-main-text'}>{mainText}</div>\n {!!secondaryText && <div className={'list-item-secondary-text'}>{secondaryText}</div>}\n </div>\n {\n !!note &&\n <>\n {\n !!noteTooltip &&\n <div className={'list-item-note with-tooltip'}>\n <TooltipWrapper label={noteTooltip}\n size={size === Size.Large ? Size.Medium : size === Size.Small ? Size.XSmall : Size.Small}\n position={'top'}\n withArrow={true}>\n {note}\n </TooltipWrapper>\n </div>\n }\n {\n !noteTooltip &&\n <div className={'list-item-note'}>\n {note}\n </div>\n }\n </>\n }\n {\n !!dropdown &&\n <div className={'list-item-actions'}\n onMouseEnter={() => setInAction(!dropdown?.disabled)}\n onMouseLeave={() => setInAction(false)}>\n <DropdownButton {...dropdown}\n disabled={disabled || dropdown.disabled}\n icon={variant === 'overlay'\n ? <SystemIcons.ArrowDropDown/>\n : <SystemIcons.MoreVertical/>}\n />\n </div>\n }\n </Row>\n );\n};\n\nexport default ListRow;\n\n"],"file":"ListRow.js"}
1
+ {"version":3,"sources":["../../../src/List/ListRow.tsx"],"names":["React","styled","COLORS","ComponentTextStyle","ComponentLStyling","ComponentMStyling","ComponentSStyling","ComponentXSStyling","ComponentXXSStyling","TooltipWrapper","DropdownButton","SystemIcons","Size","Z_INDEXES","Row","div","neutral_100","neutral_600","white","primary_20","primary_700","hover","primary_100","primary_800","active","focus","neutral_300","Regular","ListRow","size","Medium","variant","icon","mainText","secondaryText","dropdown","note","noteTooltip","disabled","action","inAction","setInAction","useState","handleKeyPress","e","key","rowClassName","concat","undefined","Large","Small","XSmall"],"mappings":";;;;AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,OAAOC,MAAP,MAAmB,mBAAnB;AACA,SAAQC,MAAR,EAAgBC,kBAAhB,QAAyC,WAAzC;AAEA,SACEC,iBADF,EAEEC,iBAFF,EAGEC,iBAHF,EAIEC,kBAJF,EAKEC,mBALF,QAMO,sBANP;AAQA,SAAQC,cAAR,QAA6B,aAA7B;AACA,SAAQC,cAAR,QAA6B,aAA7B;AACA,SAAQC,WAAR,QAA0B,UAA1B;AACA,SAAQC,IAAR,QAAmB,UAAnB;AACA,SAAQC,SAAR,QAAwB,qBAAxB;AAEA,MAAMC,GAAG,GAAGb,MAAM,CAACc,GAAI;AACvB;AACA;AACA;AACA;AACA,6BAA6Bb,MAAM,CAACc,WAAY;AAChD;AACA;AACA;AACA,WAAWd,MAAM,CAACe,WAAY;AAC9B,sBAAsBf,MAAM,CAACgB,KAAM;AACnC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,wBAAwBhB,MAAM,CAACiB,UAAW;AAC1C,aAAajB,MAAM,CAACkB,WAAY;AAChC,eAAeP,SAAS,CAACQ,KAAM;AAC/B;AACA;AACA;AACA,wBAAwBnB,MAAM,CAACoB,WAAY;AAC3C,aAAapB,MAAM,CAACqB,WAAY;AAChC;AACA,eAAeV,SAAS,CAACW,MAAO;AAChC;AACA;AACA;AACA;AACA;AACA,eAAeX,SAAS,CAACY,KAAM;AAC/B;AACA;AACA;AACA;AACA,eAAevB,MAAM,CAACwB,WAAY;AAClC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQpB,iBAAiB,CAACH,kBAAkB,CAACwB,OAApB,EAA6B,IAA7B,CAAmC;AAC5D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQtB,iBAAiB,CAACF,kBAAkB,CAACwB,OAApB,EAA6B,IAA7B,CAAmC;AAC5D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQvB,iBAAiB,CAACD,kBAAkB,CAACwB,OAApB,EAA6B,IAA7B,CAAmC;AAC5D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMnB,mBAAmB,CAACL,kBAAkB,CAACwB,OAApB,EAA6B,IAA7B,CAAmC;AAC5D;AACA;AACA;AACA,aAAazB,MAAM,CAACe,WAAY;AAChC;AACA,MAAMV,kBAAkB,CAACJ,kBAAkB,CAACwB,OAApB,EAA6B,IAA7B,CAAmC;AAC3D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAazB,MAAM,CAACe,WAAY;AAChC;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CA7JA;;AA6KA,MAAMW,OAAuC,GAAG,CAAC;AACEC,EAAAA,IAAI,GAAGjB,IAAI,CAACkB,MADd;AAEEC,EAAA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sFF,eAAeX,OAAf","sourcesContent":["import * as React from 'react';\nimport styled from 'styled-components';\nimport {COLORS, ComponentTextStyle} from '../styles';\n\nimport {\n ComponentLStyling,\n ComponentMStyling,\n ComponentSStyling,\n ComponentXSStyling,\n ComponentXXSStyling\n} from '../styles/typography';\nimport {DropdownButtonProps} from '../Dropdown/DropdownButtonTypes';\nimport {TooltipWrapper} from '../Tooltips';\nimport {DropdownButton} from '../Dropdown';\nimport {SystemIcons} from '../icons';\nimport {Size} from '../types';\nimport {Z_INDEXES} from '../styles/z-indexes';\n\nconst Row = styled.div`\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: center;\n border-bottom: 1px solid ${COLORS.neutral_100};\n box-sizing: border-box;\n position: relative;\n\n color: ${COLORS.neutral_600};\n background-color: ${COLORS.white};\n\n\n cursor: default;\n\n &.interactive {\n cursor: pointer;\n }\n\n &.interactive.disabled {\n cursor: not-allowed;\n }\n\n &.interactive:hover:not(.in-action):not(.disabled) {\n background-color: ${COLORS.primary_20};\n color: ${COLORS.primary_700};\n z-index: ${Z_INDEXES.hover};\n }\n\n &.interactive:active:not(.in-action):not(.disabled) {\n background-color: ${COLORS.primary_100};\n color: ${COLORS.primary_800};\n box-shadow: none;\n z-index: ${Z_INDEXES.active};\n }\n\n &.interactive:focus {\n outline: none;\n box-shadow: 0 4px 12px rgba(46, 127, 161, 0.25), 0 0 8px #2E7FA1;\n z-index: ${Z_INDEXES.focus};\n }\n\n &.disabled {\n .list-item-icon, .list-item-content, .list-item-note, .list-item-actions {\n color: ${COLORS.neutral_300};\n }\n }\n\n\n &.small {\n min-height: 48px;\n padding: 0 8px;\n\n .list-item-icon {\n margin-right: 8px;\n }\n\n .list-item-main-text {\n ${ComponentSStyling(ComponentTextStyle.Regular, null)}\n }\n\n .list-item-actions {\n margin-right: -8px;\n }\n }\n\n &.medium {\n min-height: 56px;\n padding: 0 12px;\n\n .list-item-icon {\n margin-right: 12px;\n }\n\n .list-item-main-text {\n ${ComponentMStyling(ComponentTextStyle.Regular, null)}\n }\n\n .list-item-actions {\n margin-right: -12px;\n }\n }\n\n &.large {\n min-height: 64px;\n padding: 0 16px;\n\n .list-item-icon {\n margin-right: 16px;\n }\n\n .list-item-main-text {\n ${ComponentLStyling(ComponentTextStyle.Regular, null)}\n }\n\n .list-item-actions {\n margin-right: -16px;\n }\n }\n\n &.overlay {\n padding: 0 4px;\n\n .list-item-actions {\n margin-right: -4px;\n }\n }\n\n .list-item-icon {\n width: 24px;\n height: 24px;\n\n svg {\n width: 24px;\n height: 24px;\n }\n }\n\n .list-item-content {\n flex-grow: 1;\n display: flex;\n flex-direction: column;\n }\n\n .list-item-main-text {\n }\n\n .list-item-secondary-text {\n ${ComponentXXSStyling(ComponentTextStyle.Regular, null)}\n }\n\n .list-item-note {\n color: ${COLORS.neutral_600};\n word-break: initial;\n ${ComponentXSStyling(ComponentTextStyle.Regular, null)}\n }\n\n .list-item-note.with-tooltip {\n cursor: pointer;\n\n > div {\n text-decoration-line: underline;\n text-decoration-style: dashed;\n text-underline-offset: 1px;\n text-decoration-thickness: 1px;\n }\n }\n\n .list-item-actions {\n color: ${COLORS.neutral_600};\n display: flex;\n align-items: center;\n\n button div {\n background-color: transparent;\n }\n }\n`;\n\n\ntype Props = {\n size?: Size;\n variant?: 'normal' | 'overlay';\n icon?: React.ReactNode;\n mainText: string;\n secondaryText?: string;\n dropdown?: Pick<DropdownButtonProps, 'items' | 'onClick' | 'disabled' | 'width'>;\n note?: string;\n noteTooltip?: string;\n disabled?: boolean;\n action?: () => void;\n};\n\nconst ListRow: React.FunctionComponent<Props> = ({\n size = Size.Medium,\n variant = 'normal',\n icon,\n mainText,\n secondaryText,\n dropdown,\n note,\n noteTooltip,\n disabled = false,\n action\n }: Props) => {\n\n const [inAction, setInAction] = React.useState<Boolean>(false);\n\n const handleKeyPress = (e: any) => {\n if (e.key === 'Enter') {\n action && action()\n }\n }\n\n const rowClassName = (inAction ? 'in-action ' : '')\n .concat(disabled ? 'disabled ' : '')\n .concat(!!action ? 'interactive ' : '')\n .concat('list-item-row ')\n .concat(`${variant} `)\n .concat(`${size}`);\n\n return (\n <Row tabIndex={!!action && !disabled ? 0 : undefined}\n className={rowClassName}\n onKeyPress={(e) => !disabled && handleKeyPress(e)}\n onClick={e => {\n !disabled && action && action();\n }}\n data-hj-suppress>\n {\n !!icon &&\n <div className={'list-item-icon'}>{icon}</div>\n }\n <div className={'list-item-content'}>\n <div className={'list-item-main-text'}>{mainText}</div>\n {!!secondaryText && <div className={'list-item-secondary-text'}>{secondaryText}</div>}\n </div>\n {\n !!note &&\n <>\n {\n !!noteTooltip &&\n <div className={'list-item-note with-tooltip'}>\n <TooltipWrapper label={noteTooltip}\n size={size === Size.Large ? Size.Medium : size === Size.Small ? Size.XSmall : Size.Small}\n position={'top'}\n withArrow={true}>\n {note}\n </TooltipWrapper>\n </div>\n }\n {\n !noteTooltip &&\n <div className={'list-item-note'}>\n {note}\n </div>\n }\n </>\n }\n {\n !!dropdown &&\n <div className={'list-item-actions'}\n onMouseEnter={() => setInAction(!dropdown?.disabled)}\n onMouseLeave={() => setInAction(false)}>\n <DropdownButton {...dropdown}\n disabled={disabled || dropdown.disabled}\n icon={variant === 'overlay'\n ? <SystemIcons.ArrowDropDown/>\n : <SystemIcons.MoreVertical/>}\n />\n </div>\n }\n </Row>\n );\n};\n\nexport default ListRow;\n\n"],"file":"ListRow.js"}
@@ -2,7 +2,6 @@ import _pt from "prop-types";
2
2
  import * as React from 'react';
3
3
  import styled from 'styled-components';
4
4
  import { COLORS } from '../styles';
5
- import { Size } from '../types';
6
5
  import { LoadingMedium, LoadingSmall } from '../icons/systemicons/SystemIcons';
7
6
  const LoadingWrapper = styled.div`
8
7
  height: 100%;
@@ -28,16 +27,16 @@ const LoadingWrapper = styled.div`
28
27
  `;
29
28
 
30
29
  const LoadingIndicator = ({
31
- size = Size.Medium,
30
+ size = 'medium',
32
31
  color = COLORS.primary
33
32
  }) => {
34
33
  switch (size) {
35
- case Size.Medium:
34
+ case 'medium':
36
35
  return /*#__PURE__*/React.createElement(LoadingWrapper, null, /*#__PURE__*/React.createElement(LoadingMedium, {
37
36
  color: color
38
37
  }));
39
38
 
40
- case Size.Small:
39
+ case 'small':
41
40
  return /*#__PURE__*/React.createElement(LoadingWrapper, null, /*#__PURE__*/React.createElement(LoadingSmall, {
42
41
  color: color
43
42
  }));
@@ -50,6 +49,7 @@ const LoadingIndicator = ({
50
49
  };
51
50
 
52
51
  LoadingIndicator.propTypes = {
52
+ size: _pt.oneOf(['small', 'medium']),
53
53
  color: _pt.string
54
54
  };
55
55
  export default LoadingIndicator;
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/LoadingIndicator/LoadingIndicator.tsx"],"names":["React","styled","COLORS","Size","LoadingMedium","LoadingSmall","LoadingWrapper","div","LoadingIndicator","size","Medium","color","primary","Small"],"mappings":";AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,OAAOC,MAAP,MAAmB,mBAAnB;AACA,SAASC,MAAT,QAAuB,WAAvB;AACA,SAASC,IAAT,QAAqB,UAArB;AACA,SAASC,aAAT,EAAwBC,YAAxB,QAA4C,kCAA5C;AAEA,MAAMC,cAAc,GAAGL,MAAM,CAACM,GAAI;AAClC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CArBA;;AA4BA,MAAMC,gBAAgB,GAAG,CAAC;AAAEC,EAAAA,IAAI,GAAGN,IAAI,CAACO,MAAd;AAAsBC,EAAAA,KAAK,GAAGT,MAAM,CAACU;AAArC,CAAD,KAA2E;AAClG,UAAQH,IAAR;AACE,SAAKN,IAAI,CAACO,MAAV;AACE,0BACE,oBAAC,cAAD,qBACE,oBAAC,aAAD;AAAe,QAAA,KAAK,EAAEC;AAAtB,QADF,CADF;;AAKF,SAAKR,IAAI,CAACU,KAAV;AACE,0BACE,oBAAC,cAAD,qBACE,oBAAC,YAAD;AAAc,QAAA,KAAK,EAAEF;AAArB,QADF,CADF;;AAKF;AACE,0BACE,oBAAC,cAAD,qBACE,oBAAC,aAAD;AAAe,QAAA,KAAK,EAAEA;AAAtB,QADF,CADF;AAdJ;AAoBD,CArBD;;;AAHEA,EAAAA,K;;AA0BF,eAAeH,gBAAf","sourcesContent":["import * as React from 'react';\nimport styled from 'styled-components';\nimport { COLORS } from '../styles';\nimport { Size } from '../types';\nimport { LoadingMedium, LoadingSmall } from '../icons/systemicons/SystemIcons';\n\nconst LoadingWrapper = styled.div`\n height: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n\n svg {\n animation-name: spin;\n animation-duration: 1s;\n animation-iteration-count: infinite;\n transform-origin: 50% 50%;\n\n @keyframes spin {\n from {\n transform: rotate(0deg);\n }\n to {\n transform: rotate(360deg);\n }\n }\n }\n`;\n\ntype LoadingIndicatorProps = {\n size?: Size.Small | Size.Medium;\n color?: string;\n};\n\nconst LoadingIndicator = ({ size = Size.Medium, color = COLORS.primary }: LoadingIndicatorProps) => {\n switch (size) {\n case Size.Medium:\n return (\n <LoadingWrapper>\n <LoadingMedium color={color} />\n </LoadingWrapper>\n );\n case Size.Small:\n return (\n <LoadingWrapper>\n <LoadingSmall color={color} />\n </LoadingWrapper>\n );\n default:\n return (\n <LoadingWrapper>\n <LoadingMedium color={color} />\n </LoadingWrapper>\n );\n }\n};\n\nexport default LoadingIndicator;\n"],"file":"LoadingIndicator.js"}
1
+ {"version":3,"sources":["../../../src/LoadingIndicator/LoadingIndicator.tsx"],"names":["React","styled","COLORS","LoadingMedium","LoadingSmall","LoadingWrapper","div","LoadingIndicator","size","color","primary"],"mappings":";AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,OAAOC,MAAP,MAAmB,mBAAnB;AACA,SAASC,MAAT,QAAuB,WAAvB;AACA,SAASC,aAAT,EAAwBC,YAAxB,QAA4C,kCAA5C;AAEA,MAAMC,cAAc,GAAGJ,MAAM,CAACK,GAAI;AAClC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CArBA;;AA4BA,MAAMC,gBAAgB,GAAG,CAAC;AAAEC,EAAAA,IAAI,GAAG,QAAT;AAAmBC,EAAAA,KAAK,GAAGP,MAAM,CAACQ;AAAlC,CAAD,KAAwE;AAC/F,UAAQF,IAAR;AACE,SAAK,QAAL;AACE,0BACE,oBAAC,cAAD,qBACE,oBAAC,aAAD;AAAe,QAAA,KAAK,EAAEC;AAAtB,QADF,CADF;;AAKF,SAAK,OAAL;AACE,0BACE,oBAAC,cAAD,qBACE,oBAAC,YAAD;AAAc,QAAA,KAAK,EAAEA;AAArB,QADF,CADF;;AAKF;AACE,0BACE,oBAAC,cAAD,qBACE,oBAAC,aAAD;AAAe,QAAA,KAAK,EAAEA;AAAtB,QADF,CADF;AAdJ;AAoBD,CArBD;;;AAJED,EAAAA,I,aAAO,O,EAAU,Q;AACjBC,EAAAA,K;;AA0BF,eAAeF,gBAAf","sourcesContent":["import * as React from 'react';\nimport styled from 'styled-components';\nimport { COLORS } from '../styles';\nimport { LoadingMedium, LoadingSmall } from '../icons/systemicons/SystemIcons';\n\nconst LoadingWrapper = styled.div`\n height: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n\n svg {\n animation-name: spin;\n animation-duration: 1s;\n animation-iteration-count: infinite;\n transform-origin: 50% 50%;\n\n @keyframes spin {\n from {\n transform: rotate(0deg);\n }\n to {\n transform: rotate(360deg);\n }\n }\n }\n`;\n\ntype LoadingIndicatorProps = {\n size?: 'small' | 'medium';\n color?: string;\n};\n\nconst LoadingIndicator = ({ size = 'medium', color = COLORS.primary }: LoadingIndicatorProps) => {\n switch (size) {\n case 'medium':\n return (\n <LoadingWrapper>\n <LoadingMedium color={color} />\n </LoadingWrapper>\n );\n case 'small':\n return (\n <LoadingWrapper>\n <LoadingSmall color={color} />\n </LoadingWrapper>\n );\n default:\n return (\n <LoadingWrapper>\n <LoadingMedium color={color} />\n </LoadingWrapper>\n );\n }\n};\n\nexport default LoadingIndicator;\n"],"file":"LoadingIndicator.js"}
@@ -9,6 +9,7 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
9
9
  import * as React from 'react';
10
10
  import ReactModal from 'react-modal';
11
11
  import { BOXSHADOWS } from '../styles';
12
+ import { Z_INDEXES } from '../styles/z-indexes';
12
13
  const ModalContainerStyles = {
13
14
  content: {
14
15
  top: '50%',
@@ -29,7 +30,7 @@ const ModalContainerStyles = {
29
30
  const modalTransitions = `
30
31
  .ReactModal__Overlay {
31
32
  opacity: 0;
32
- z-index: 100;
33
+ z-index: ${Z_INDEXES.backdrop};
33
34
  }
34
35
 
35
36
  .ReactModal__Overlay--after-open {
@@ -38,6 +39,7 @@ const modalTransitions = `
38
39
  }
39
40
 
40
41
  .ReactModal__Content{
42
+ z-index: ${Z_INDEXES.modal};
41
43
  opacity:0;
42
44
  transform: translate(-50%, -50%) scale(1.1, 1.1);
43
45
  }
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/Modals/ModalContainer.tsx"],"names":["React","ReactModal","BOXSHADOWS","ModalContainerStyles","content","top","left","right","bottom","marginRight","width","height","borderRadius","boxSizing","margin","overflow","boxShadow","BOXSHADOW_L3","modalTransitions","ModalContainer","Component","modalHeight","modalWidth","modalOverflow","componentDidMount","defaultStyles","overlay","backgroundColor","document","querySelector","head","getElementsByTagName","style","createElement","setAttribute","appendChild","createTextNode","render","id","showModal","closeModal","children","padding","minWidth","maxWidth","props","sizes","GetSize","GetOverflow","stylesConfiguration","Object","assign","styles","getElementById"],"mappings":";;;;;;;;AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,OAAOC,UAAP,MAAuB,aAAvB;AACA,SAASC,UAAT,QAA2B,WAA3B;AAEA,MAAMC,oBAAoB,GAAG;AAC3BC,EAAAA,OAAO,EAAE;AACPC,IAAAA,GAAG,EAAE,KADE;AAEPC,IAAAA,IAAI,EAAE,KAFC;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,UAAU,EAA5F;AAAgG,MAAA,KAAK,EAAEY,MAAvG;AAA+G,MAAA,UAAU,EAAExB,QAAQ,CAACyB,cAAT,CAAwB,MAAxB,KAAmC;AAA9J,OACGZ,QADH,CADF;AAKD;;AA/BoF;;gBAAjFtB,c;AAdJmB,EAAAA,E;AACAC,EAAAA,S;AACAC,EAAAA,U;AACAC,EAAAA,Q;AACApB,EAAAA,W;AACAC,EAAAA,U;AACAC,EAAAA,a;AACAmB,EAAAA,O;AACAC,EAAAA,Q;AACAC,EAAAA,Q;;;AAuCF,eAAezB,cAAf","sourcesContent":["import * as React from 'react';\nimport ReactModal from 'react-modal';\nimport { BOXSHADOWS } from '../styles';\n\nconst ModalContainerStyles = {\n content: {\n top: '50%',\n left: '50%',\n right: 'auto',\n bottom: 'auto',\n marginRight: '-50%',\n width: '640px',\n height: '320px',\n borderRadius: '8px',\n boxSizing: 'border-box' as any,\n margin: 0,\n overflow: 'auto',\n boxShadow: BOXSHADOWS.BOXSHADOW_L3,\n },\n};\n\n//override modal classes to define the animations\nconst modalTransitions = `\n.ReactModal__Overlay {\n opacity: 0;\n z-index: 100;\n}\n\n.ReactModal__Overlay--after-open {\n opacity: 1;\n transition: opacity 150ms cubic-bezier(0.22, 0.61, 0.35, 1);\n}\n\n.ReactModal__Content{\n opacity:0;\n transform: translate(-50%, -50%) scale(1.1, 1.1);\n}\n\n.ReactModal__Content--after-open{\n opacity: 1;\n transform: translate(-50%, -50%) scale(1.0, 1.0);\n transition: transform 150ms ease-in-out, opacity 150ms cubic-bezier(0.22, 0.61, 0.35, 1);\n}\n\n.ReactModal__Overlay--before-close {\n opacity: 0;\n transition: opacity 120ms linear;\n}\n\n.ReactModal__Content--before-close{\n opacity: 0;\n transform: translate(-50%, -50%) scale(1.1, 1.1);\n transition: transform 120ms ease-in-out, opacity 120ms cubic-bezier(0.55, 0.05, 0.67, 0.19);\n}\n`;\n\ntype ModalContainerProps = {\n id?: string;\n showModal: boolean;\n closeModal: () => void;\n children: any;\n modalHeight?: any;\n modalWidth?: any;\n modalOverflow?: string;\n padding?: string;\n minWidth?: string;\n maxWidth?: string;\n};\n\ntype ModalContainerState = {};\n\nclass ModalContainer extends React.Component<ModalContainerProps, ModalContainerState> {\n componentDidMount() {\n if (ReactModal.defaultStyles.overlay) {\n ReactModal.defaultStyles.overlay.backgroundColor = 'rgba(0,0,0,0.5)';\n }\n\n //append style node to override modal transition classes\n if (!document.querySelector('[modal-custom-styling=\"active\"]')) {\n const head = document.head || document.getElementsByTagName('head')[0];\n const style = document.createElement('style');\n style.setAttribute('modal-custom-styling', 'active');\n head.appendChild(style);\n style.appendChild(document.createTextNode(modalTransitions));\n }\n }\n\n GetSize = (modalHeight: string = 'auto', modalWidth: string = 'auto') => ({ height: modalHeight, width: modalWidth });\n GetOverflow = (modalOverflow: string = 'visible') => modalOverflow;\n render() {\n const { id, showModal, closeModal, children, modalHeight, modalWidth, modalOverflow, padding, minWidth = '', maxWidth = '' } = this.props;\n const sizes = this.GetSize(modalHeight, modalWidth);\n const { height, width } = sizes;\n const overflow = this.GetOverflow(modalOverflow);\n const stylesConfiguration = Object.assign({ ...ModalContainerStyles.content }, { height, width, padding, overflow, minWidth, maxWidth });\n const styles = { content: stylesConfiguration };\n\n return (\n <ReactModal id={id} isOpen={showModal} closeTimeoutMS={120} onRequestClose={() => closeModal()} style={styles} appElement={document.getElementById('root') || ''}>\n {children}\n </ReactModal>\n );\n }\n}\n\nexport default ModalContainer;\n"],"file":"ModalContainer.js"}
1
+ {"version":3,"sources":["../../../src/Modals/ModalContainer.tsx"],"names":["React","ReactModal","BOXSHADOWS","Z_INDEXES","ModalContainerStyles","content","top","left","right","bottom","marginRight","width","height","borderRadius","boxSizing","margin","overflow","boxShadow","BOXSHADOW_L3","modalTransitions","backdrop","modal","ModalContainer","Component","modalHeight","modalWidth","modalOverflow","componentDidMount","defaultStyles","overlay","backgroundColor","document","querySelector","head","getElementsByTagName","style","createElement","setAttribute","appendChild","createTextNode","render","id","showModal","closeModal","children","padding","minWidth","maxWidth","props","sizes","GetSize","GetOverflow","stylesConfiguration","Object","assign","styles","getElementById"],"mappings":";;;;;;;;AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,OAAOC,UAAP,MAAuB,aAAvB;AACA,SAASC,UAAT,QAA2B,WAA3B;AACA,SAAQC,SAAR,QAAwB,qBAAxB;AAEA,MAAMC,oBAAoB,GAAG;AAC3BC,EAAAA,OAAO,EAAE;AACPC,IAAAA,GAAG,EAAE,KADE;AAEPC,IAAAA,IAAI,EAAE,KAFC;AAGPC,IAAAA,KAAK,EAAE,MAHA;AAIPC,IAAAA,MAAM,EAAE,MAJD;AAKPC,IAAAA,WAAW,EAAE,MALN;AAMPC,IAAAA,KAAK,EAAE,OANA;AAOPC,IAAAA,MAAM,EAAE,OAPD;AAQPC,IAAAA,YAAY,EAAE,KARP;AASPC,IAAAA,SAAS,EAAE,YATJ;AAUPC,IAAAA,MAAM,EAAE,CAVD;AAWPC,IAAAA,QAAQ,EAAE,MAXH;AAYPC,IAAAA,SAAS,EAAEf,UAAU,CAACgB;AAZf;AADkB,CAA7B,C,CAiBA;;AACA,MAAMC,gBAAgB,GAAI;AAC1B;AACA;AACA,aAAahB,SAAS,CAACiB,QAAS;AAChC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAajB,SAAS,CAACkB,KAAM;AAC7B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAjCA;;AAkDA,MAAMC,cAAN,SAA6BtB,KAAK,CAACuB,SAAnC,CAAuF;AAAA;AAAA;;AAAA,qCAgB3E,CAACC,WAAmB,GAAG,MAAvB,EAA+BC,UAAkB,GAAG,MAApD,MAAgE;AAAEb,MAAAA,MAAM,EAAEY,WAAV;AAAuBb,MAAAA,KAAK,EAAEc;AAA9B,KAAhE,CAhB2E;;AAAA,yCAiBvE,CAACC,aAAqB,GAAG,SAA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mBAAmBlD,oBAAoB,CAACC,OAAxC,GAAmD;AAAEO,MAAAA,MAAF;AAAUD,MAAAA,KAAV;AAAiBkC,MAAAA,OAAjB;AAA0B7B,MAAAA,QAA1B;AAAoC8B,MAAAA,QAApC;AAA8CC,MAAAA;AAA9C,KAAnD,CAA5B;AACA,UAAMQ,MAAM,GAAG;AAAElD,MAAAA,OAAO,EAAE+C;AAAX,KAAf;AAEA,wBACE,oBAAC,UAAD;AAAY,MAAA,EAAE,EAAEX,EAAhB;AAAoB,MAAA,MAAM,EAAEC,SAA5B;AAAuC,MAAA,cAAc,EAAE,GAAvD;AAA4D,MAAA,cAAc,EAAE,MAAMC,UAAU,EAA5F;AAAgG,MAAA,KAAK,EAAEY,MAAvG;AAA+G,MAAA,UAAU,EAAExB,QAAQ,CAACyB,cAAT,CAAwB,MAAxB,KAAmC;AAA9J,OACGZ,QADH,CADF;AAKD;;AA/BoF;;gBAAjFtB,c;AAdJmB,EAAAA,E;AACAC,EAAAA,S;AACAC,EAAAA,U;AACAC,EAAAA,Q;AACApB,EAAAA,W;AACAC,EAAAA,U;AACAC,EAAAA,a;AACAmB,EAAAA,O;AACAC,EAAAA,Q;AACAC,EAAAA,Q;;;AAuCF,eAAezB,cAAf","sourcesContent":["import * as React from 'react';\nimport ReactModal from 'react-modal';\nimport { BOXSHADOWS } from '../styles';\nimport {Z_INDEXES} from '../styles/z-indexes';\n\nconst ModalContainerStyles = {\n content: {\n top: '50%',\n left: '50%',\n right: 'auto',\n bottom: 'auto',\n marginRight: '-50%',\n width: '640px',\n height: '320px',\n borderRadius: '8px',\n boxSizing: 'border-box' as any,\n margin: 0,\n overflow: 'auto',\n boxShadow: BOXSHADOWS.BOXSHADOW_L3,\n },\n};\n\n//override modal classes to define the animations\nconst modalTransitions = `\n.ReactModal__Overlay {\n opacity: 0;\n z-index: ${Z_INDEXES.backdrop};\n}\n\n.ReactModal__Overlay--after-open {\n opacity: 1;\n transition: opacity 150ms cubic-bezier(0.22, 0.61, 0.35, 1);\n}\n\n.ReactModal__Content{\n z-index: ${Z_INDEXES.modal};\n opacity:0;\n transform: translate(-50%, -50%) scale(1.1, 1.1);\n}\n\n.ReactModal__Content--after-open{\n opacity: 1;\n transform: translate(-50%, -50%) scale(1.0, 1.0);\n transition: transform 150ms ease-in-out, opacity 150ms cubic-bezier(0.22, 0.61, 0.35, 1);\n}\n\n.ReactModal__Overlay--before-close {\n opacity: 0;\n transition: opacity 120ms linear;\n}\n\n.ReactModal__Content--before-close{\n opacity: 0;\n transform: translate(-50%, -50%) scale(1.1, 1.1);\n transition: transform 120ms ease-in-out, opacity 120ms cubic-bezier(0.55, 0.05, 0.67, 0.19);\n}\n`;\n\ntype ModalContainerProps = {\n id?: string;\n showModal: boolean;\n closeModal: () => void;\n children: any;\n modalHeight?: any;\n modalWidth?: any;\n modalOverflow?: string;\n padding?: string;\n minWidth?: string;\n maxWidth?: string;\n};\n\ntype ModalContainerState = {};\n\nclass ModalContainer extends React.Component<ModalContainerProps, ModalContainerState> {\n componentDidMount() {\n if (ReactModal.defaultStyles.overlay) {\n ReactModal.defaultStyles.overlay.backgroundColor = 'rgba(0,0,0,0.5)';\n }\n\n //append style node to override modal transition classes\n if (!document.querySelector('[modal-custom-styling=\"active\"]')) {\n const head = document.head || document.getElementsByTagName('head')[0];\n const style = document.createElement('style');\n style.setAttribute('modal-custom-styling', 'active');\n head.appendChild(style);\n style.appendChild(document.createTextNode(modalTransitions));\n }\n }\n\n GetSize = (modalHeight: string = 'auto', modalWidth: string = 'auto') => ({ height: modalHeight, width: modalWidth });\n GetOverflow = (modalOverflow: string = 'visible') => modalOverflow;\n render() {\n const { id, showModal, closeModal, children, modalHeight, modalWidth, modalOverflow, padding, minWidth = '', maxWidth = '' } = this.props;\n const sizes = this.GetSize(modalHeight, modalWidth);\n const { height, width } = sizes;\n const overflow = this.GetOverflow(modalOverflow);\n const stylesConfiguration = Object.assign({ ...ModalContainerStyles.content }, { height, width, padding, overflow, minWidth, maxWidth });\n const styles = { content: stylesConfiguration };\n\n return (\n <ReactModal id={id} isOpen={showModal} closeTimeoutMS={120} onRequestClose={() => closeModal()} style={styles} appElement={document.getElementById('root') || ''}>\n {children}\n </ReactModal>\n );\n }\n}\n\nexport default ModalContainer;\n"],"file":"ModalContainer.js"}
@@ -1,6 +1,7 @@
1
1
  import styled from 'styled-components';
2
2
  import { COLORS } from '../styles';
3
3
  import { ComponentMStyling, ComponentTextStyle } from '../styles/typography';
4
+ import { Z_INDEXES } from '../styles/z-indexes';
4
5
  const NavItem = styled.div`
5
6
  ${ComponentMStyling(ComponentTextStyle.Regular, COLORS.neutral_600)}
6
7
 
@@ -25,6 +26,7 @@ const NavItem = styled.div`
25
26
  }
26
27
 
27
28
  &.active:not(.disabled) {
29
+ z-index: ${Z_INDEXES.active};
28
30
  background-color: ${COLORS.neutral_20};
29
31
  color: ${COLORS.neutral_800};
30
32
  &:after {
@@ -41,6 +43,7 @@ const NavItem = styled.div`
41
43
  }
42
44
 
43
45
  &:hover:not(.disabled) {
46
+ z-index: ${Z_INDEXES.hover};
44
47
  background-color: ${COLORS.primary_20};
45
48
  color: ${COLORS.primary_700};
46
49
  &:after {
@@ -49,6 +52,7 @@ const NavItem = styled.div`
49
52
  }
50
53
 
51
54
  &:focus:not(.disabled) {
55
+ z-index: ${Z_INDEXES.focus};
52
56
  box-shadow: 0px 0px 8px ${COLORS.primary_500}, 0px 4px 12px rgba(46, 127, 161, 0.25);
53
57
  outline: none;
54
58
  &:after {
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/NavItem/NavItem.tsx"],"names":["styled","COLORS","ComponentMStyling","ComponentTextStyle","NavItem","div","Regular","neutral_600","neutral_20","neutral_800","primary_600","neutral_300","neutral_100","primary_20","primary_700","primary_500"],"mappings":"AAAA,OAAOA,MAAP,MAAmB,mBAAnB;AAEA,SAASC,MAAT,QAAuB,WAAvB;AACA,SAASC,iBAAT,EAA4BC,kBAA5B,QAAsD,sBAAtD;AAEA,MAAMC,OAAO,GAAGJ,MAAM,CAACK,GAAI;AAC3B,IAAIH,iBAAiB,CAACC,kBAAkB,CAACG,OAApB,EAA6BL,MAAM,CAACM,WAApC,CAAiD;AACtE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,wBAAwBN,MAAM,CAACO,UAAW;AAC1C,aAAaP,MAAM,CAACQ,WAAY;AAChC;AACA,0BAA0BR,MAAM,CAACS,WAAY;AAC7C;AACA;AACA;AACA;AACA,aAAaT,MAAM,CAACU,WAAY;AAChC,wBAAwBV,MAAM,CAACW,WAAY;AAC3C;AACA,0BAA0BX,MAAM,CAACW,WAAY;AAC7C;AACA;AACA;AACA;AACA,wBAAwBX,MAAM,CAACY,UAAW;AAC1C,aAAaZ,MAAM,CAACa,WAAY;AAChC;AACA,0BAA0Bb,MAAM,CAACS,WAAY;AAC7C;AACA;AACA;AACA;AACA,8BAA8BT,MAAM,CAACc,WAAY;AACjD;AACA;AACA,0BAA0Bd,MAAM,CAACS,WAAY;AAC7C;AACA;AACA,CAtDA;AAwDA,eAAeN,OAAf","sourcesContent":["import styled from 'styled-components';\n\nimport { COLORS } from '../styles';\nimport { ComponentMStyling, ComponentTextStyle } from '../styles/typography';\n\nconst NavItem = styled.div`\n ${ComponentMStyling(ComponentTextStyle.Regular, COLORS.neutral_600)}\n\n margin: 0;\n padding: 0 21px 0 21px;\n height: 64px;\n\n display: flex;\n align-items: center;\n text-align: center;\n position: relative;\n\n &:after {\n content: '';\n display: block;\n position: absolute;\n bottom: 0;\n left: 0;\n right: 0;\n height: 3px;\n background-color: transparent;\n }\n\n &.active:not(.disabled) {\n background-color: ${COLORS.neutral_20};\n color: ${COLORS.neutral_800};\n &:after {\n background-color: ${COLORS.primary_600};\n }\n }\n\n &.disabled {\n color: ${COLORS.neutral_300};\n background-color: ${COLORS.neutral_100};\n &:after {\n background-color: ${COLORS.neutral_100};\n }\n }\n\n &:hover:not(.disabled) {\n background-color: ${COLORS.primary_20};\n color: ${COLORS.primary_700};\n &:after {\n background-color: ${COLORS.primary_600};\n }\n }\n\n &:focus:not(.disabled) {\n box-shadow: 0px 0px 8px ${COLORS.primary_500}, 0px 4px 12px rgba(46, 127, 161, 0.25);\n outline: none;\n &:after {\n background-color: ${COLORS.primary_600};\n }\n }\n`;\n\nexport default NavItem;\n"],"file":"NavItem.js"}
1
+ {"version":3,"sources":["../../../src/NavItem/NavItem.tsx"],"names":["styled","COLORS","ComponentMStyling","ComponentTextStyle","Z_INDEXES","NavItem","div","Regular","neutral_600","active","neutral_20","neutral_800","primary_600","neutral_300","neutral_100","hover","primary_20","primary_700","focus","primary_500"],"mappings":"AAAA,OAAOA,MAAP,MAAmB,mBAAnB;AAEA,SAASC,MAAT,QAAuB,WAAvB;AACA,SAASC,iBAAT,EAA4BC,kBAA5B,QAAsD,sBAAtD;AACA,SAAQC,SAAR,QAAwB,qBAAxB;AAEA,MAAMC,OAAO,GAAGL,MAAM,CAACM,GAAI;AAC3B,IAAIJ,iBAAiB,CAACC,kBAAkB,CAACI,OAApB,EAA6BN,MAAM,CAACO,WAApC,CAAiD;AACtE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAeJ,SAAS,CAACK,MAAO;AAChC,wBAAwBR,MAAM,CAACS,UAAW;AAC1C,aAAaT,MAAM,CAACU,WAAY;AAChC;AACA,0BAA0BV,MAAM,CAACW,WAAY;AAC7C;AACA;AACA;AACA;AACA,aAAaX,MAAM,CAACY,WAAY;AAChC,wBAAwBZ,MAAM,CAACa,WAAY;AAC3C;AACA,0BAA0Bb,MAAM,CAACa,WAAY;AAC7C;AACA;AACA;AACA;AACA,eAAeV,SAAS,CAACW,KAAM;AAC/B,wBAAwBd,MAAM,CAACe,UAAW;AAC1C,aAAaf,MAAM,CAACgB,WAAY;AAChC;AACA,0BAA0BhB,MAAM,CAACW,WAAY;AAC7C;AACA;AACA;AACA;AACA,eAAeR,SAAS,CAACc,KAAM;AAC/B,8BAA8BjB,MAAM,CAACkB,WAAY;AACjD;AACA;AACA,0BAA0BlB,MAAM,CAACW,WAAY;AAC7C;AACA;AACA,CAzDA;AA2DA,eAAeP,OAAf","sourcesContent":["import styled from 'styled-components';\n\nimport { COLORS } from '../styles';\nimport { ComponentMStyling, ComponentTextStyle } from '../styles/typography';\nimport {Z_INDEXES} from '../styles/z-indexes';\n\nconst NavItem = styled.div`\n ${ComponentMStyling(ComponentTextStyle.Regular, COLORS.neutral_600)}\n\n margin: 0;\n padding: 0 21px 0 21px;\n height: 64px;\n\n display: flex;\n align-items: center;\n text-align: center;\n position: relative;\n\n &:after {\n content: '';\n display: block;\n position: absolute;\n bottom: 0;\n left: 0;\n right: 0;\n height: 3px;\n background-color: transparent;\n }\n\n &.active:not(.disabled) {\n z-index: ${Z_INDEXES.active};\n background-color: ${COLORS.neutral_20};\n color: ${COLORS.neutral_800};\n &:after {\n background-color: ${COLORS.primary_600};\n }\n }\n\n &.disabled {\n color: ${COLORS.neutral_300};\n background-color: ${COLORS.neutral_100};\n &:after {\n background-color: ${COLORS.neutral_100};\n }\n }\n\n &:hover:not(.disabled) {\n z-index: ${Z_INDEXES.hover};\n background-color: ${COLORS.primary_20};\n color: ${COLORS.primary_700};\n &:after {\n background-color: ${COLORS.primary_600};\n }\n }\n\n &:focus:not(.disabled) {\n z-index: ${Z_INDEXES.focus};\n box-shadow: 0px 0px 8px ${COLORS.primary_500}, 0px 4px 12px rgba(46, 127, 161, 0.25);\n outline: none;\n &:after {\n background-color: ${COLORS.primary_600};\n }\n }\n`;\n\nexport default NavItem;\n"],"file":"NavItem.js"}
@@ -1,25 +1,24 @@
1
1
  import _pt from "prop-types";
2
2
  import * as React from 'react';
3
3
  import styled from 'styled-components';
4
- import { Size } from '../types';
5
4
  import { COLORS } from '..';
6
5
  const ContentWrapper = styled.div`
7
- width: ${props => props.size === Size.Small ? '16px' : props.size === Size.Large ? '24px' : '20px'};
8
- height: ${props => props.size === Size.Small ? '16px' : props.size === Size.Large ? '24px' : '20px'};
9
- padding: ${props => props.size === Size.Small ? '3px' : props.size === Size.Large ? '4px' : '4px'};
6
+ width: ${props => props.size === 'small' ? '16px' : props.size === 'large' ? '24px' : '20px'};
7
+ height: ${props => props.size === 'small' ? '16px' : props.size === 'large' ? '24px' : '20px'};
8
+ padding: ${props => props.size === 'small' ? '3px' : props.size === 'large' ? '4px' : '4px'};
10
9
  box-sizing: border-box;
11
10
  `;
12
11
  const Content = styled.div`
13
12
  background-color: ${props => props.variant === 'positive' ? COLORS.correct_500 : COLORS.critical_500};
14
- height: ${props => props.size === Size.Small ? '10px' : props.size === Size.Large ? '16px' : '12px'};
15
- width: ${props => props.size === Size.Small ? '10px' : props.size === Size.Large ? '16px' : '12px'};
16
- border-radius: ${props => props.size === Size.Small ? '10px' : props.size === Size.Large ? '16px' : '12px'};
17
- border: ${props => props.size === Size.Small ? '2px solid ' + COLORS.white : props.size === Size.Large ? '3px solid ' + COLORS.white : '2px solid ' + COLORS.white};
13
+ height: ${props => props.size === 'small' ? '10px' : props.size === 'large' ? '16px' : '12px'};
14
+ width: ${props => props.size === 'small' ? '10px' : props.size === 'large' ? '16px' : '12px'};
15
+ border-radius: ${props => props.size === 'small' ? '10px' : props.size === 'large' ? '16px' : '12px'};
16
+ border: ${props => props.size === 'small' ? '2px solid ' + COLORS.white : props.size === 'large' ? '3px solid ' + COLORS.white : '2px solid ' + COLORS.white};
18
17
  box-sizing: border-box;
19
18
  `;
20
19
 
21
20
  const NotificationDot = ({
22
- size = Size.Medium,
21
+ size = 'medium',
23
22
  variant,
24
23
  testId
25
24
  }) => {
@@ -34,6 +33,7 @@ const NotificationDot = ({
34
33
  };
35
34
 
36
35
  NotificationDot.propTypes = {
36
+ size: _pt.string,
37
37
  variant: _pt.oneOf(['critical', 'positive']).isRequired,
38
38
  testId: _pt.string
39
39
  };
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/NotificationDot/NotificationDot.tsx"],"names":["React","styled","Size","COLORS","ContentWrapper","div","props","size","Small","Large","Content","variant","correct_500","critical_500","white","NotificationDot","Medium","testId"],"mappings":";AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,OAAOC,MAAP,MAAmB,mBAAnB;AACA,SAASC,IAAT,QAAqB,UAArB;AACA,SAAQC,MAAR,QAAqB,IAArB;AAQA,MAAMC,cAAc,GAAGH,MAAM,CAACI,GAAuB;AACrD,WAAYC,KAAD,IAAWA,KAAK,CAACC,IAAN,KAAeL,IAAI,CAACM,KAApB,GAA4B,MAA5B,GAAsCF,KAAK,CAACC,IAAN,KAAeL,IAAI,CAACO,KAApB,GAA4B,MAA5B,GAAqC,MAAQ;AACzG,YAAaH,KAAD,IAAWA,KAAK,CAACC,IAAN,KAAeL,IAAI,CAACM,KAApB,GAA4B,MAA5B,GAAsCF,KAAK,CAACC,IAAN,KAAeL,IAAI,CAACO,KAApB,GAA4B,MAA5B,GAAqC,MAAQ;AAC1G,aAAcH,KAAD,IAAWA,KAAK,CAACC,IAAN,KAAeL,IAAI,CAACM,KAApB,GAA4B,KAA5B,GAAqCF,KAAK,CAACC,IAAN,KAAeL,IAAI,CAACO,KAApB,GAA4B,KAA5B,GAAoC,KAAO;AACxG;AACA,CALA;AAOA,MAAMC,OAAO,GAAGT,MAAM,CAACI,GAAuB;AAC9C,sBAAuBC,KAAD,IAAWA,KAAK,CAACK,OAAN,KAAkB,UAAlB,GAA+BR,MAAM,CAACS,WAAtC,GAAoDT,MAAM,CAACU,YAAa;AACzG,YAAaP,KAAD,IAAWA,KAAK,CAACC,IAAN,KAAeL,IAAI,CAACM,KAApB,GAA4B,MAA5B,GAAsCF,KAAK,CAACC,IAAN,KAAeL,IAAI,CAACO,KAApB,GAA4B,MAA5B,GAAqC,MAAQ;AAC1G,WAAYH,KAAD,IAAWA,KAAK,CAACC,IAAN,KAAeL,IAAI,CAACM,KAApB,GAA4B,MAA5B,GAAsCF,KAAK,CAACC,IAAN,KAAeL,IAAI,CAACO,KAApB,GAA4B,MAA5B,GAAqC,MAAQ;AACzG,mBAAoBH,KAAD,IAAWA,KAAK,CAACC,IAAN,KAAeL,IAAI,CAACM,KAApB,GAA4B,MAA5B,GAAsCF,KAAK,CAACC,IAAN,KAAeL,IAAI,CAACO,KAApB,GAA4B,MAA5B,GAAqC,MAAQ;AACjH,YAAaH,KAAD,IAAWA,KAAK,CAACC,IAAN,KAAeL,IAAI,CAACM,KAApB,GAA4B,eAAeL,MAAM,CAACW,KAAlD,GAA2DR,KAAK,CAACC,IAAN,KAAeL,IAAI,CAACO,KAApB,GAA4B,eAAeN,MAAM,CAACW,KAAlD,GAA0D,eAAeX,MAAM,CAACW,KAAO;AACzK;AACA,CAPA;;AASA,MAAMC,eAA2D,GAAG,CAAC;AAACR,EAAAA,IAAI,GAAGL,IAAI,CAACc,MAAb;AAAqBL,EAAAA,OAArB;AAA8BM,EAAAA;AAA9B,CAAD,KAA2C;AAC7G,sBACE,oBAAC,cAAD;AAAgB,IAAA,IAAI,EAAEV,IAAtB;AAA4B,IAAA,OAAO,EAAEI;AAArC,kBACE,oBAAC,OAAD;AAAS,IAAA,IAAI,EAAEJ,IAAf;AAAqB,IAAA,OAAO,EAAEI,OAA9B;AAAuC,mBAAaM;AAApD,IADF,CADF;AAKD,CAND;;;AApBEN,EAAAA,O,aAAS,U,EAAa,U;AACtBM,EAAAA,M;;AA2BF,eAAeF,eAAf","sourcesContent":["import * as React from 'react';\nimport styled from 'styled-components';\nimport { Size } from '../types';\nimport {COLORS} from '..';\n\nexport interface NotificationProps {\n size?: Size.Small | Size.Medium | Size.Large;\n variant: 'critical' | 'positive';\n testId?: string;\n}\n\nconst ContentWrapper = styled.div<NotificationProps>`\n width: ${(props) => props.size === Size.Small ? '16px' : (props.size === Size.Large ? '24px' : '20px')};\n height: ${(props) => props.size === Size.Small ? '16px' : (props.size === Size.Large ? '24px' : '20px')};\n padding: ${(props) => props.size === Size.Small ? '3px' : (props.size === Size.Large ? '4px' : '4px')};\n box-sizing: border-box;\n`;\n\nconst Content = styled.div<NotificationProps>`\n background-color: ${(props) => props.variant === 'positive' ? COLORS.correct_500 : COLORS.critical_500};\n height: ${(props) => props.size === Size.Small ? '10px' : (props.size === Size.Large ? '16px' : '12px')};\n width: ${(props) => props.size === Size.Small ? '10px' : (props.size === Size.Large ? '16px' : '12px')};\n border-radius: ${(props) => props.size === Size.Small ? '10px' : (props.size === Size.Large ? '16px' : '12px')};\n border: ${(props) => props.size === Size.Small ? '2px solid ' + COLORS.white : (props.size === Size.Large ? '3px solid ' + COLORS.white : '2px solid ' + COLORS.white)};\n box-sizing: border-box;\n`;\n\nconst NotificationDot: React.FunctionComponent<NotificationProps> = ({size = Size.Medium, variant, testId}) => {\n return (\n <ContentWrapper size={size} variant={variant}>\n <Content size={size} variant={variant} data-testid={testId}/>\n </ContentWrapper>\n );\n};\n\nexport default NotificationDot;\n"],"file":"NotificationDot.js"}
1
+ {"version":3,"sources":["../../../src/NotificationDot/NotificationDot.tsx"],"names":["React","styled","COLORS","ContentWrapper","div","props","size","Content","variant","correct_500","critical_500","white","NotificationDot","testId"],"mappings":";AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,OAAOC,MAAP,MAAmB,mBAAnB;AACA,SAAQC,MAAR,QAAqB,IAArB;AAQA,MAAMC,cAAc,GAAGF,MAAM,CAACG,GAAuB;AACrD,WAAYC,KAAD,IAAWA,KAAK,CAACC,IAAN,KAAe,OAAf,GAAyB,MAAzB,GAAmCD,KAAK,CAACC,IAAN,KAAe,OAAf,GAAyB,MAAzB,GAAkC,MAAQ;AACnG,YAAaD,KAAD,IAAWA,KAAK,CAACC,IAAN,KAAe,OAAf,GAAyB,MAAzB,GAAmCD,KAAK,CAACC,IAAN,KAAe,OAAf,GAAyB,MAAzB,GAAkC,MAAQ;AACpG,aAAcD,KAAD,IAAWA,KAAK,CAACC,IAAN,KAAe,OAA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CAND;;;AArBEP,EAAAA,I;AACAE,EAAAA,O,aAAS,U,EAAa,U;AACtBK,EAAAA,M;;AA2BF,eAAeD,eAAf","sourcesContent":["import * as React from 'react';\nimport styled from 'styled-components';\nimport {COLORS} from '..';\n\nexport interface NotificationProps {\n size?: string;\n variant: 'critical' | 'positive';\n testId?: string;\n}\n\nconst ContentWrapper = styled.div<NotificationProps>`\n width: ${(props) => props.size === 'small' ? '16px' : (props.size === 'large' ? '24px' : '20px')};\n height: ${(props) => props.size === 'small' ? '16px' : (props.size === 'large' ? '24px' : '20px')};\n padding: ${(props) => props.size === 'small' ? '3px' : (props.size === 'large' ? '4px' : '4px')};\n box-sizing: border-box;\n`;\n\nconst Content = styled.div<NotificationProps>`\n background-color: ${(props) => props.variant === 'positive' ? COLORS.correct_500 : COLORS.critical_500};\n height: ${(props) => props.size === 'small' ? '10px' : (props.size === 'large' ? '16px' : '12px')};\n width: ${(props) => props.size === 'small' ? '10px' : (props.size === 'large' ? '16px' : '12px')};\n border-radius: ${(props) => props.size === 'small' ? '10px' : (props.size === 'large' ? '16px' : '12px')};\n border: ${(props) => props.size === 'small' ? '2px solid ' + COLORS.white : (props.size === 'large' ? '3px solid ' + COLORS.white : '2px solid ' + COLORS.white)};\n box-sizing: border-box;\n`;\n\nconst NotificationDot: React.FunctionComponent<NotificationProps> = ({size = 'medium', variant, testId}) => {\n return (\n <ContentWrapper size={size} variant={variant}>\n <Content size={size} variant={variant} data-testid={testId}/>\n </ContentWrapper>\n );\n};\n\nexport default NotificationDot;\n"],"file":"NotificationDot.js"}
@@ -2,7 +2,6 @@ import React from 'react';
2
2
  import { render } from '@testing-library/react';
3
3
  import 'jest-styled-components';
4
4
  import { NotificationDot } from '..';
5
- import { Size } from '../../types';
6
5
  import COLORS from '../../styles/colors';
7
6
  describe('<NotificationDot />', () => {
8
7
  it('renders positive small notification dot', async () => {
@@ -10,7 +9,7 @@ describe('<NotificationDot />', () => {
10
9
  getByTestId
11
10
  } = render( /*#__PURE__*/React.createElement(NotificationDot, {
12
11
  variant: "positive",
13
- size: Size.Small,
12
+ size: "small",
14
13
  testId: "testId"
15
14
  }));
16
15
  expect(getByTestId('testId')).toHaveStyleRule('background-color', COLORS.correct_500);
@@ -21,7 +20,7 @@ describe('<NotificationDot />', () => {
21
20
  getByTestId
22
21
  } = render( /*#__PURE__*/React.createElement(NotificationDot, {
23
22
  variant: "critical",
24
- size: Size.Large,
23
+ size: "large",
25
24
  testId: "testId"
26
25
  }));
27
26
  expect(getByTestId('testId')).toHaveStyleRule('background-color', COLORS.critical_500);
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../src/NotificationDot/__tests__/NotificationDot.test.tsx"],"names":["React","render","NotificationDot","Size","COLORS","describe","it","getByTestId","Small","expect","toHaveStyleRule","correct_500","white","Large","critical_500"],"mappings":"AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,SAASC,MAAT,QAAuB,wBAAvB;AACA,OAAO,wBAAP;AACA,SAASC,eAAT,QAAgC,IAAhC;AACA,SAASC,IAAT,QAAqB,aAArB;AACA,OAAOC,MAAP,MAAmB,qBAAnB;AAEAC,QAAQ,CAAC,qBAAD,EAAuB,MAAI;AAC/BC,EAAAA,EAAE,CAAC,yCAAD,EAA4C,YAAY;AACtD,UAAK;AAACC,MAAAA;AAAD,QAAgBN,MAAM,eACvB,oBAAC,eAAD;AAAiB,MAAA,OAAO,EAAC,UAAzB;AAAoC,MAAA,IAAI,EAAEE,IAAI,CAACK,KAA/C;AAAsD,MAAA,MAAM,EAAC;AAA7D,MADuB,CAA3B;AAGAC,IAAAA,MAAM,CAACF,WAAW,CAAC,QAAD,CAAZ,CAAN,CAA8BG,eAA9B,CAA8C,kBAA9C,EAAiEN,MAAM,CAACO,WAAxE;AACAF,IAAAA,MAAM,CAACF,WAAW,CAAC,QAAD,CAAZ,CAAN,CAA8BG,eAA9B,CAA8C,QAA9C,EAAwD,eAAeN,MAAM,CAACQ,KAA9E;AACH,GANC,CAAF;AAQAN,EAAAA,EAAE,CAAC,yCAAD,EAA4C,YAAY;AACtD,UAAK;AAACC,MAAAA;AAAD,QAAgBN,MAAM,eACvB,oBAAC,eAAD;AAAiB,MAAA,OAAO,EAAC,UAAzB;AAAoC,MAAA,IAAI,EAAEE,IAAI,CAACU,KAA/C;AAAsD,MAAA,MAAM,EAAC;AAA7D,MADuB,CAA3B;AAGAJ,IAAAA,MAAM,CAACF,WAAW,CAAC,QAAD,CAAZ,CAAN,CAA8BG,eAA9B,CAA8C,kBAA9C,EAAiEN,MAAM,CAACU,YAAxE;AACAL,IAAAA,MAAM,CAACF,WAAW,CAAC,QAAD,CAAZ,CAAN,CAA8BG,eAA9B,CAA8C,QAA9C,EAAwD,eAAeN,MAAM,CAACQ,KAA9E;AACH,GANC,CAAF;AAQAN,EAAAA,EAAE,CAAC,0CAAD,EAA6C,YAAY;AACvD,UAAK;AAACC,MAAAA;AAAD,QAAgBN,MAAM,eACvB,oBAAC,eAAD;AAAiB,MAAA,OAAO,EAAC,UAAzB;AAAoC,MAAA,MAAM,EAAC;AAA3C,MADuB,CAA3B;AAGAQ,IAAAA,MAAM,CAACF,WAAW,CAAC,QAAD,CAAZ,CAAN,CAA8BG,eAA9B,CAA8C,kBAA9C,EAAiEN,MAAM,CAACU,YAAxE;AACAL,IAAAA,MAAM,CAACF,WAAW,CAAC,QAAD,CAAZ,CAAN,CAA8BG,eAA9B,CAA8C,QAA9C,EAAwD,eAAeN,MAAM,CAACQ,KAA9E;AACH,GANC,CAAF;AAOH,CAxBO,CAAR","sourcesContent":["import React from 'react';\nimport { render } from '@testing-library/react';\nimport 'jest-styled-components';\nimport { NotificationDot } from '..';\nimport { Size } from '../../types';\nimport COLORS from '../../styles/colors';\n\ndescribe('<NotificationDot />',()=>{\n it('renders positive small notification dot', async () => {\n const{getByTestId} = render(\n <NotificationDot variant='positive' size={Size.Small} testId='testId'/>\n );\n expect(getByTestId('testId')).toHaveStyleRule('background-color',COLORS.correct_500);\n expect(getByTestId('testId')).toHaveStyleRule('border', '2px solid ' + COLORS.white);\n });\n\n it('renders critical large notification dot', async () => {\n const{getByTestId} = render(\n <NotificationDot variant='critical' size={Size.Large} testId='testId'/>\n );\n expect(getByTestId('testId')).toHaveStyleRule('background-color',COLORS.critical_500);\n expect(getByTestId('testId')).toHaveStyleRule('border', '3px solid ' + COLORS.white);\n });\n\n it('renders critical medium notification dot', async () => {\n const{getByTestId} = render(\n <NotificationDot variant='critical' testId='testId'/>\n );\n expect(getByTestId('testId')).toHaveStyleRule('background-color',COLORS.critical_500);\n expect(getByTestId('testId')).toHaveStyleRule('border', '2px solid ' + COLORS.white);\n });\n});"],"file":"NotificationDot.test.js"}
1
+ {"version":3,"sources":["../../../../src/NotificationDot/__tests__/NotificationDot.test.tsx"],"names":["React","render","NotificationDot","COLORS","describe","it","getByTestId","expect","toHaveStyleRule","correct_500","white","critical_500"],"mappings":"AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,SAASC,MAAT,QAAuB,wBAAvB;AACA,OAAO,wBAAP;AACA,SAASC,eAAT,QAAgC,IAAhC;AACA,OAAOC,MAAP,MAAmB,qBAAnB;AAEAC,QAAQ,CAAC,qBAAD,EAAuB,MAAI;AAC/BC,EAAAA,EAAE,CAAC,yCAAD,EAA4C,YAAY;AACtD,UAAK;AAACC,MAAAA;AAAD,QAAgBL,MAAM,eACvB,oBAAC,eAAD;AAAiB,MAAA,OAAO,EAAC,UAAzB;AAAoC,MAAA,IAAI,EAAC,OAAzC;AAAiD,MAAA,MAAM,EAAC;AAAxD,MADuB,CAA3B;AAGAM,IAAAA,MAAM,CAACD,WAAW,CAAC,QAAD,CAAZ,CAAN,CAA8BE,eAA9B,CAA8C,kBAA9C,EAAiEL,MAAM,CAACM,WAAxE;AACAF,IAAAA,MAAM,CAACD,WAAW,CAAC,QAAD,CAAZ,CAAN,CAA8BE,eAA9B,CAA8C,QAA9C,EAAwD,eAAeL,MAAM,CAACO,KAA9E;AACH,GANC,CAAF;AAQAL,EAAAA,EAAE,CAAC,yCAAD,EAA4C,YAAY;AACtD,UAAK;AAACC,MAAAA;AAAD,QAAgBL,MAAM,eACvB,oBAAC,eAAD;AAAiB,MAAA,OAAO,EAAC,UAAzB;AAAoC,MAAA,IAAI,EAAC,OAAzC;AAAiD,MAAA,MAAM,EAAC;AAAxD,MADuB,CAA3B;AAGAM,IAAAA,MAAM,CAACD,WAAW,CAAC,QAAD,CAAZ,CAAN,CAA8BE,eAA9B,CAA8C,kBAA9C,EAAiEL,MAAM,CAACQ,YAAxE;AACAJ,IAAAA,MAAM,CAACD,WAAW,CAAC,QAAD,CAAZ,CAAN,CAA8BE,eAA9B,CAA8C,QAA9C,EAAwD,eAAeL,MAAM,CAACO,KAA9E;AACH,GANC,CAAF;AAQAL,EAAAA,EAAE,CAAC,0CAAD,EAA6C,YAAY;AACvD,UAAK;AAACC,MAAAA;AAAD,QAAgBL,MAAM,eACvB,oBAAC,eAAD;AAAiB,MAAA,OAAO,EAAC,UAAzB;AAAoC,MAAA,MAAM,EAAC;AAA3C,MADuB,CAA3B;AAGAM,IAAAA,MAAM,CAACD,WAAW,CAAC,QAAD,CAAZ,CAAN,CAA8BE,eAA9B,CAA8C,kBAA9C,EAAiEL,MAAM,CAACQ,YAAxE;AACAJ,IAAAA,MAAM,CAACD,WAAW,CAAC,QAAD,CAAZ,CAAN,CAA8BE,eAA9B,CAA8C,QAA9C,EAAwD,eAAeL,MAAM,CAACO,KAA9E;AACH,GANC,CAAF;AAOH,CAxBO,CAAR","sourcesContent":["import React from 'react';\nimport { render } from '@testing-library/react';\nimport 'jest-styled-components';\nimport { NotificationDot } from '..';\nimport COLORS from '../../styles/colors';\n\ndescribe('<NotificationDot />',()=>{\n it('renders positive small notification dot', async () => {\n const{getByTestId} = render(\n <NotificationDot variant='positive' size='small' testId='testId'/>\n );\n expect(getByTestId('testId')).toHaveStyleRule('background-color',COLORS.correct_500);\n expect(getByTestId('testId')).toHaveStyleRule('border', '2px solid ' + COLORS.white);\n });\n\n it('renders critical large notification dot', async () => {\n const{getByTestId} = render(\n <NotificationDot variant='critical' size='large' testId='testId'/>\n );\n expect(getByTestId('testId')).toHaveStyleRule('background-color',COLORS.critical_500);\n expect(getByTestId('testId')).toHaveStyleRule('border', '3px solid ' + COLORS.white);\n });\n\n it('renders critical medium notification dot', async () => {\n const{getByTestId} = render(\n <NotificationDot variant='critical' testId='testId'/>\n );\n expect(getByTestId('testId')).toHaveStyleRule('background-color',COLORS.critical_500);\n expect(getByTestId('testId')).toHaveStyleRule('border', '2px solid ' + COLORS.white);\n });\n});"],"file":"NotificationDot.test.js"}
@@ -5,6 +5,7 @@ import { NavLink } from 'react-router-dom';
5
5
  import { BREAKPOINTS, COLORS, ComponentTextStyle } from '../styles';
6
6
  import { ChevronLeft, ChevronRight, MoreHorizontal } from '../icons/systemicons/SystemIcons';
7
7
  import { ComponentMStyling } from '../styles/typography';
8
+ import { Z_INDEXES } from '../styles/z-indexes';
8
9
  const Container = styled.nav`
9
10
  margin: 20px 0;
10
11
  display: flex;
@@ -40,23 +41,27 @@ const Item = styled.li`
40
41
 
41
42
  &:focus,
42
43
  &:focus-within {
44
+ z-index: ${Z_INDEXES.focus};
43
45
  box-shadow: 0px 4px 12px rgba(46, 127, 161, 0.25), 0px 0px 8px #2e7fa1;
44
46
  outline-width: 0;
45
47
  }
46
48
  }
47
49
 
48
50
  & > a:hover {
51
+ z-index: ${Z_INDEXES.hover};
49
52
  color: ${COLORS.primary_800};
50
53
  background-color: ${COLORS.primary_20};
51
54
  box-shadow: none;
52
55
  }
53
56
  & > a:active {
57
+ z-index: ${Z_INDEXES.active};
54
58
  color: ${COLORS.primary_700};
55
59
  background-color: ${COLORS.primary_100};
56
60
  box-shadow: none;
57
61
  }
58
62
 
59
63
  & > a.active {
64
+ z-index: ${Z_INDEXES.active};
60
65
  color: ${COLORS.neutral_800};
61
66
  background-color: ${COLORS.neutral_20};
62
67
  cursor: default;
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/Paginator/Paginator.tsx"],"names":["React","styled","NavLink","BREAKPOINTS","COLORS","ComponentTextStyle","ChevronLeft","ChevronRight","MoreHorizontal","ComponentMStyling","Container","nav","MEDIUM","Items","ul","Item","li","Regular","neutral_600","primary_800","primary_20","primary_700","primary_100","neutral_800","neutral_20","Dots","ItemContent","ItemSelected","primary_500","Step","up","target","disabled","page","onPageChange","testId","cursor","neutral_300","Paginator","pageCount","currentPage","baseUrl","pages","from","to","i","push","findIndex","item","map"],"mappings":";AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,OAAOC,MAAP,MAAmB,mBAAnB;AACA,SAAQC,OAAR,QAAsB,kBAAtB;AACA,SAAQC,WAAR,EAAqBC,MAArB,EAA6BC,kBAA7B,QAAsD,WAAtD;AACA,SAAQC,WAAR,EAAqBC,YAArB,EAAmCC,cAAnC,QAAwD,kCAAxD;AACA,SAAQC,iBAAR,QAAgC,sBAAhC;AAEA,MAAMC,SAAS,GAAGT,MAAM,CAACU,GAAI;AAC7B;AACA;AACA;AACA;AACA,IAAIR,WAAW,CAACS,MAAO;AACvB;AACA;AACA,CARA;AAUA,MAAMC,KAAK,GAAGZ,MAAM,CAACa,EAAG;AACxB;AACA;AACA;AACA;AACA,CALA;AAOA,MAAMC,IAAI,GAAGd,MAAM,CAACe,EAAG;AACvB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMP,iBAAiB,CAACJ,kBAAkB,CAACY,OAApB,EAA6Bb,MAAM,CAACc,WAApC,CAAiD;AACxE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAad,MAAM,CAACe,WAAY;AAChC,wBAAwBf,MAAM,CAACgB,UAAW;AAC1C;AACA;AACA;AACA,aAAahB,MAAM,CAACiB,WAAY;AAChC,wBAAwBjB,MAAM,CAACkB,WAAY;AAC3C;AACA;AACA;AACA;AACA,aAAalB,MAAM,CAACmB,WAAY;AAChC,wBAAwBnB,MAAM,CAACoB,UA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BAAwB,oBAAC,YAAD,OAF1B,CALJ,CADF,CADD,CA9BH,EA4CGM,SAAS,GAAG,CAAZ,IAAiBC,WAAW,IAAID,SAAS,GAAG,CAA5C,iBACC,oBAAC,IAAD,qBACE,oBAAC,cAAD;AAAgB,IAAA,KAAK,EAAEnC,MAAM,CAACc;AAA9B,IADF,CA7CJ,EAiDGwB,KAAK,CAACK,SAAN,CAAgBC,IAAI,IAAIA,IAAI,KAAKT,SAAjC,MAAgD,CAAC,CAAjD,IAAsDA,SAAS,KAAK,CAApE,iBACC,oBAAC,IAAD,qBACE,oBAAC,OAAD;AACE,IAAA,EAAE,EAAG,GAAEE,OAAQ,IAAGF,SAAU,EAD9B;AAEE,IAAA,OAAO,EAAE,MAAM;AACb,UAAIL,YAAJ,EAAkBA,YAAY,CAACK,SAAD,CAAZ;AACnB;AAJH,kBAKI,oBAAC,WAAD,qBACC,kCAAOA,SAAP,CADD,EAEEC,WAAW,KAAKD,SAAhB,iBAA6B,oBAAC,YAAD,OAF/B,CALJ,CADF,CAlDJ,eA+DE,oBAAC,IAAD;AACE,IAAA,EAAE,MADJ;AAEE,IAAA,MAAM,EAAG,GAAEE,OAAQ,IAAGD,WAAW,GAAG,CAAE,EAFxC;AAGE,IAAA,IAAI,EAAEA,WAAW,GAAG,CAHtB;AAIE,IAAA,QAAQ,EAAEA,WAAW,KAAKD,SAJ5B;AAKE,IAAA,YAAY,EAAE,MAAM;AAClB,UAAIL,YAAJ,EAAkBA,YAAY,CAACM,WAAW,GAAG,CAAf,CAAZ;AACnB,KAPH;AAQE,IAAA,MAAM,EAAC;AART,IA/DF,CADF,CADF;AA8ED,CApGD;;;AAxCED,EAAAA,S;AACAC,EAAAA,W;AACAC,EAAAA,O;AACAP,EAAAA,Y;;AA2IF,eAAeI,SAAf","sourcesContent":["import * as React from 'react';\nimport styled from 'styled-components';\nimport {NavLink} from 'react-router-dom';\nimport {BREAKPOINTS, COLORS, ComponentTextStyle} from '../styles';\nimport {ChevronLeft, ChevronRight, MoreHorizontal} from '../icons/systemicons/SystemIcons';\nimport {ComponentMStyling} from '../styles/typography';\n\nconst Container = styled.nav`\n margin: 20px 0;\n display: flex;\n justify-content: center;\n\n ${BREAKPOINTS.MEDIUM} {\n width: 75%;\n }\n`;\n\nconst Items = styled.ul`\n margin: 0;\n padding: 0;\n list-style: none;\n display: flex;\n`;\n\nconst Item = styled.li`\n width: 48px;\n height: 45px;\n display: flex;\n align-items: center;\n justify-content: center;\n\n & > * {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 100%;\n height: 100%;\n text-decoration: none;\n border-bottom: 3px solid transparent;\n\n ${ComponentMStyling(ComponentTextStyle.Regular, COLORS.neutral_600)}\n\n &:focus,\n &:focus-within {\n box-shadow: 0px 4px 12px rgba(46, 127, 161, 0.25), 0px 0px 8px #2e7fa1;\n outline-width: 0;\n }\n }\n\n & > a:hover {\n color: ${COLORS.primary_800};\n background-color: ${COLORS.primary_20};\n box-shadow: none;\n }\n & > a:active {\n color: ${COLORS.primary_700};\n background-color: ${COLORS.primary_100};\n box-shadow: none;\n }\n\n & > a.active {\n color: ${COLORS.neutral_800};\n background-color: ${COLORS.neutral_20};\n cursor: default;\n box-shadow: none;\n &:hover {\n color: ${COLORS.primary_800};\n background-color: ${COLORS.primary_20};\n }\n &:active {\n color: ${COLORS.primary_700};\n background-color: ${COLORS.primary_100};\n }\n }\n`;\n\nconst Dots = styled(Item)`\n padding-top: 1%;\n cursor: not-allowed;\n`;\n\nconst ItemContent = styled('div')`\n width: 100%;\n text-align:center;\n display: table-cell;\n vertical-align:middle;\n`\nconst ItemSelected = styled('div')`\n justify-content: center;\n margin: 0 20%;\n border-radius: 4px;\n text-align: center;\n height: 4px;\n background-color: ${COLORS.primary_500}\n`\n\ntype PaginatorProps = {\n pageCount: number;\n currentPage: number;\n baseUrl: string;\n onPageChange?: (page: number) => void;\n};\n\nconst Step = ({\n up = true,\n target = '',\n disabled = false,\n page,\n onPageChange,\n testId,\n}: {\n up: boolean;\n target: string;\n disabled: boolean;\n page: number;\n onPageChange?: (page: number) => void;\n testId?: string;\n}) => {\n if (disabled)\n return (\n <Item style={{ cursor: 'not-allowed' }} data-testid={`${testId}_Disabled`}>\n {up ? <ChevronRight size=\"20\" color={COLORS.neutral_300} /> : <ChevronLeft size=\"20\" color={COLORS.neutral_300} />}\n </Item>\n );\n return (\n <Item data-testid={`${testId}_Enabled`}>\n <NavLink\n to={target}\n onClick={() => {\n if (onPageChange) onPageChange(page);\n }}>\n {up ? <ChevronRight size=\"20\" /> : <ChevronLeft />}\n </NavLink>\n </Item>\n );\n};\n\nconst Paginator = ({ pageCount = 1, currentPage = 1, baseUrl = '', onPageChange }: PaginatorProps) => {\n const pages = [];\n let from = 2;\n let to = 4;\n if (pageCount === 0) return null;\n\n if (pageCount > 1) {\n if (currentPage >= 4 && currentPage <= pageCount - 2) {\n from = currentPage - 1;\n to = currentPage + 1;\n } else if (pageCount - 2 > 1 && currentPage > pageCount - 2) {\n from = pageCount - 3;\n to = pageCount - 1;\n }\n if (to > pageCount) {\n to = pageCount;\n }\n for (let i = from; i <= to; i += 1) {\n pages.push(i);\n }\n }\n\n return (\n <Container>\n <Items>\n <Step\n up={false}\n target={`${baseUrl}/${currentPage - 1}`}\n page={currentPage - 1}\n disabled={currentPage === 1}\n onPageChange={() => {\n if (onPageChange) onPageChange(currentPage - 1);\n }}\n testId=\"Test-StepLeft\"\n />\n {pages.findIndex(item => item === 1) === -1 && (\n <Item>\n <NavLink\n to={`${baseUrl}/1`}\n onClick={() => {\n if (onPageChange) onPageChange(1);\n }}>\n <ItemContent>\n <span>1</span>\n {currentPage === 1 && <ItemSelected />}\n </ItemContent>\n </NavLink>\n </Item>\n )}\n {currentPage >= 4 && pageCount > 5 && pageCount && pages.findIndex(item => item === 1) === -1 && (\n <Dots>\n <MoreHorizontal color={COLORS.neutral_600} />\n </Dots>\n )}\n {pages.map(page => (\n <Item key={page}>\n <NavLink\n to={`${baseUrl}/${page}`}\n onClick={() => {\n if (onPageChange) onPageChange(page);\n }}>\n <ItemContent>\n <span>{page}</span>\n {currentPage === page && <ItemSelected />}\n </ItemContent>\n </NavLink>\n </Item>\n ))}\n {pageCount > 5 && currentPage <= pageCount - 3 && (\n <Dots>\n <MoreHorizontal color={COLORS.neutral_600} />\n </Dots>\n )}\n {pages.findIndex(item => item === pageCount) === -1 && pageCount !== 1 && (\n <Item>\n <NavLink\n to={`${baseUrl}/${pageCount}`}\n onClick={() => {\n if (onPageChange) onPageChange(pageCount);\n }}>\n <ItemContent>\n <span>{pageCount}</span>\n {currentPage === pageCount && <ItemSelected />}\n </ItemContent>\n </NavLink>\n </Item>\n )}\n <Step\n up\n target={`${baseUrl}/${currentPage + 1}`}\n page={currentPage + 1}\n disabled={currentPage === pageCount}\n onPageChange={() => {\n if (onPageChange) onPageChange(currentPage + 1);\n }}\n testId=\"Test-StepRight\"\n />\n </Items>\n </Container>\n );\n};\n\nexport default Paginator;\n"],"file":"Paginator.js"}
1
+ {"version":3,"sources":["../../../src/Paginator/Paginator.tsx"],"names":["React","styled","NavLink","BREAKPOINTS","COLORS","ComponentTextStyle","ChevronLeft","ChevronRight","MoreHorizontal","ComponentMStyling","Z_INDEXES","Container","nav","MEDIUM","Items","ul","Item","li","Regular","neutral_600","focus","hover","primary_800","primary_20","active","primary_700","primary_100","neutral_800","neutral_20","Dots","ItemContent","ItemSelected","primary_500","Step","up","target","disabled","page","onPageChange","testId","cursor","neutral_300","Paginator","pageCount","currentPage","baseUrl","pages","from","to","i","push","findIndex","item","map"],"mappings":";AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,OAAOC,MAAP,MAAmB,mBAAnB;AACA,SAAQC,OAAR,QAAsB,kBAAtB;AACA,SAAQC,WAAR,EAAqBC,MAArB,EAA6BC,kBAA7B,QAAsD,WAAtD;AACA,SAAQC,WAAR,EAAqBC,YAArB,EAAmCC,cAAnC,QAAwD,kCAAxD;AACA,SAAQC,iBAAR,QAAgC,sBAAhC;AACA,SAAQC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AQ,IAAGF,SAAU,EAD9B;AAEE,IAAA,OAAO,EAAE,MAAM;AACb,UAAIL,YAAJ,EAAkBA,YAAY,CAACK,SAAD,CAAZ;AACnB;AAJH,kBAKI,oBAAC,WAAD,qBACC,kCAAOA,SAAP,CADD,EAEEC,WAAW,KAAKD,SAAhB,iBAA6B,oBAAC,YAAD,OAF/B,CALJ,CADF,CAlDJ,eA+DE,oBAAC,IAAD;AACE,IAAA,EAAE,MADJ;AAEE,IAAA,MAAM,EAAG,GAAEE,OAAQ,IAAGD,WAAW,GAAG,CAAE,EAFxC;AAGE,IAAA,IAAI,EAAEA,WAAW,GAAG,CAHtB;AAIE,IAAA,QAAQ,EAAEA,WAAW,KAAKD,SAJ5B;AAKE,IAAA,YAAY,EAAE,MAAM;AAClB,UAAIL,YAAJ,EAAkBA,YAAY,CAACM,WAAW,GAAG,CAAf,CAAZ;AACnB,KAPH;AAQE,IAAA,MAAM,EAAC;AART,IA/DF,CADF,CADF;AA8ED,CApGD;;;AAxCED,EAAAA,S;AACAC,EAAAA,W;AACAC,EAAAA,O;AACAP,EAAAA,Y;;AA2IF,eAAeI,SAAf","sourcesContent":["import * as React from 'react';\nimport styled from 'styled-components';\nimport {NavLink} from 'react-router-dom';\nimport {BREAKPOINTS, COLORS, ComponentTextStyle} from '../styles';\nimport {ChevronLeft, ChevronRight, MoreHorizontal} from '../icons/systemicons/SystemIcons';\nimport {ComponentMStyling} from '../styles/typography';\nimport {Z_INDEXES} from '../styles/z-indexes';\n\nconst Container = styled.nav`\n margin: 20px 0;\n display: flex;\n justify-content: center;\n\n ${BREAKPOINTS.MEDIUM} {\n width: 75%;\n }\n`;\n\nconst Items = styled.ul`\n margin: 0;\n padding: 0;\n list-style: none;\n display: flex;\n`;\n\nconst Item = styled.li`\n width: 48px;\n height: 45px;\n display: flex;\n align-items: center;\n justify-content: center;\n\n & > * {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 100%;\n height: 100%;\n text-decoration: none;\n border-bottom: 3px solid transparent;\n\n ${ComponentMStyling(ComponentTextStyle.Regular, COLORS.neutral_600)}\n\n &:focus,\n &:focus-within {\n z-index: ${Z_INDEXES.focus};\n box-shadow: 0px 4px 12px rgba(46, 127, 161, 0.25), 0px 0px 8px #2e7fa1;\n outline-width: 0;\n }\n }\n\n & > a:hover {\n z-index: ${Z_INDEXES.hover};\n color: ${COLORS.primary_800};\n background-color: ${COLORS.primary_20};\n box-shadow: none;\n }\n & > a:active {\n z-index: ${Z_INDEXES.active};\n color: ${COLORS.primary_700};\n background-color: ${COLORS.primary_100};\n box-shadow: none;\n }\n\n & > a.active {\n z-index: ${Z_INDEXES.active};\n color: ${COLORS.neutral_800};\n background-color: ${COLORS.neutral_20};\n cursor: default;\n box-shadow: none;\n &:hover {\n color: ${COLORS.primary_800};\n background-color: ${COLORS.primary_20};\n }\n &:active {\n color: ${COLORS.primary_700};\n background-color: ${COLORS.primary_100};\n }\n }\n`;\n\nconst Dots = styled(Item)`\n padding-top: 1%;\n cursor: not-allowed;\n`;\n\nconst ItemContent = styled('div')`\n width: 100%;\n text-align:center;\n display: table-cell;\n vertical-align:middle;\n`\nconst ItemSelected = styled('div')`\n justify-content: center;\n margin: 0 20%;\n border-radius: 4px;\n text-align: center;\n height: 4px;\n background-color: ${COLORS.primary_500}\n`\n\ntype PaginatorProps = {\n pageCount: number;\n currentPage: number;\n baseUrl: string;\n onPageChange?: (page: number) => void;\n};\n\nconst Step = ({\n up = true,\n target = '',\n disabled = false,\n page,\n onPageChange,\n testId,\n}: {\n up: boolean;\n target: string;\n disabled: boolean;\n page: number;\n onPageChange?: (page: number) => void;\n testId?: string;\n}) => {\n if (disabled)\n return (\n <Item style={{ cursor: 'not-allowed' }} data-testid={`${testId}_Disabled`}>\n {up ? <ChevronRight size=\"20\" color={COLORS.neutral_300} /> : <ChevronLeft size=\"20\" color={COLORS.neutral_300} />}\n </Item>\n );\n return (\n <Item data-testid={`${testId}_Enabled`}>\n <NavLink\n to={target}\n onClick={() => {\n if (onPageChange) onPageChange(page);\n }}>\n {up ? <ChevronRight size=\"20\" /> : <ChevronLeft />}\n </NavLink>\n </Item>\n );\n};\n\nconst Paginator = ({ pageCount = 1, currentPage = 1, baseUrl = '', onPageChange }: PaginatorProps) => {\n const pages = [];\n let from = 2;\n let to = 4;\n if (pageCount === 0) return null;\n\n if (pageCount > 1) {\n if (currentPage >= 4 && currentPage <= pageCount - 2) {\n from = currentPage - 1;\n to = currentPage + 1;\n } else if (pageCount - 2 > 1 && currentPage > pageCount - 2) {\n from = pageCount - 3;\n to = pageCount - 1;\n }\n if (to > pageCount) {\n to = pageCount;\n }\n for (let i = from; i <= to; i += 1) {\n pages.push(i);\n }\n }\n\n return (\n <Container>\n <Items>\n <Step\n up={false}\n target={`${baseUrl}/${currentPage - 1}`}\n page={currentPage - 1}\n disabled={currentPage === 1}\n onPageChange={() => {\n if (onPageChange) onPageChange(currentPage - 1);\n }}\n testId=\"Test-StepLeft\"\n />\n {pages.findIndex(item => item === 1) === -1 && (\n <Item>\n <NavLink\n to={`${baseUrl}/1`}\n onClick={() => {\n if (onPageChange) onPageChange(1);\n }}>\n <ItemContent>\n <span>1</span>\n {currentPage === 1 && <ItemSelected />}\n </ItemContent>\n </NavLink>\n </Item>\n )}\n {currentPage >= 4 && pageCount > 5 && pageCount && pages.findIndex(item => item === 1) === -1 && (\n <Dots>\n <MoreHorizontal color={COLORS.neutral_600} />\n </Dots>\n )}\n {pages.map(page => (\n <Item key={page}>\n <NavLink\n to={`${baseUrl}/${page}`}\n onClick={() => {\n if (onPageChange) onPageChange(page);\n }}>\n <ItemContent>\n <span>{page}</span>\n {currentPage === page && <ItemSelected />}\n </ItemContent>\n </NavLink>\n </Item>\n ))}\n {pageCount > 5 && currentPage <= pageCount - 3 && (\n <Dots>\n <MoreHorizontal color={COLORS.neutral_600} />\n </Dots>\n )}\n {pages.findIndex(item => item === pageCount) === -1 && pageCount !== 1 && (\n <Item>\n <NavLink\n to={`${baseUrl}/${pageCount}`}\n onClick={() => {\n if (onPageChange) onPageChange(pageCount);\n }}>\n <ItemContent>\n <span>{pageCount}</span>\n {currentPage === pageCount && <ItemSelected />}\n </ItemContent>\n </NavLink>\n </Item>\n )}\n <Step\n up\n target={`${baseUrl}/${currentPage + 1}`}\n page={currentPage + 1}\n disabled={currentPage === pageCount}\n onPageChange={() => {\n if (onPageChange) onPageChange(currentPage + 1);\n }}\n testId=\"Test-StepRight\"\n />\n </Items>\n </Container>\n );\n};\n\nexport default Paginator;\n"],"file":"Paginator.js"}
@@ -7,6 +7,7 @@ import { ArrowLineLeft, Close } from '../icons/systemicons/SystemIcons';
7
7
  import { flowDown, Right, UserMenuSectionListStyling } from '../GlobalNavigationBar/mobile/CommonStyles';
8
8
  import SwitcherMenuItem from './SwitcherMenuItem';
9
9
  import { ComponentSStyling } from '../styles/typography';
10
+ import { Z_INDEXES } from '../styles/z-indexes';
10
11
  const Menu = styled.ul`
11
12
  list-style: none;
12
13
  margin: 0;
@@ -17,7 +18,7 @@ const Menu = styled.ul`
17
18
  animation: ${flowDown} 0.2s ease-in-out;
18
19
  position: absolute;
19
20
  border-radius: 4px;
20
- z-index: 100;
21
+ z-index: ${Z_INDEXES.off_canvas};
21
22
  height: 100%;
22
23
  width: 320px;
23
24
  padding-inline-start: 0;
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/Switcher/MobileSwitcherMenu.tsx"],"names":["React","styled","BREAKPOINTS","COLORS","ComponentTextStyle","scrollBarStyling","IconButton","ArrowLineLeft","Close","flowDown","Right","UserMenuSectionListStyling","SwitcherMenuItem","ComponentSStyling","Menu","ul","white","SMALL","MenuSection","li","MenuSectionList","Top","div","neutral_600","Regular","LabelLine","span","neutral_20","MobileSwitcherMenu","header","elementsHeader","clickMenuAction","elements","useEffect","handleKeyPress","e","keyCode","document","addEventListener","removeEventListener","length","map","element","to","label","icon"],"mappings":";AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,OAAOC,MAAP,MAAmB,mBAAnB;AACA,S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ES,GAAV,CAAeC,OAAD,iBACb,oBAAC,gBAAD;AAAkB,IAAA,GAAG,EAAEA,OAAO,EAAEC,EAAhC;AAAoC,IAAA,KAAK,EAAED,OAAO,EAAEE,KAApD;AAA2D,IAAA,IAAI,EAAEF,OAAO,CAACG;AAAzE,IADD,CADH,CAFF,CAbJ,CADF;AAyBD,CAvCD;;;AANEhB,EAAAA,M;AACAC,EAAAA,c;AACAC,EAAAA,e;AACAC,EAAAA,Q;;AA4CF,eAAeJ,kBAAf","sourcesContent":["import * as React from 'react';\nimport styled from 'styled-components';\nimport {BREAKPOINTS, COLORS, ComponentTextStyle, scrollBarStyling} from '../styles';\n\nimport {UserMenuItem} from '../types';\nimport {IconButton} from '../Button';\nimport {ArrowLineLeft, Close} from '../icons/systemicons/SystemIcons';\nimport {flowDown, Right, UserMenuSectionListStyling} from '../GlobalNavigationBar/mobile/CommonStyles';\nimport SwitcherMenuItem from './SwitcherMenuItem';\nimport {ComponentSStyling} from '../styles/typography';\n\nconst Menu = styled.ul`\n list-style: none;\n margin: 0;\n background-color: ${COLORS.white};\n box-sizing: border-box;\n display: none;\n -webkit-animation: ${flowDown} 0.2s ease-in-out;\n animation: ${flowDown} 0.2s ease-in-out;\n position: absolute;\n border-radius: 4px;\n z-index: 100;\n height: 100%;\n width: 320px;\n padding-inline-start: 0;\n overflow-y: scroll;\n ${BREAKPOINTS.SMALL} {\n min-width: 360px;\n }\n\n .open & {\n display: flex;\n flex-direction: column;\n }\n\n ${scrollBarStyling};\n`;\n\nconst MenuSection = styled.li`\n padding: 8px 0;\n position: relative;\n\n .disabled-link {\n color: #21212150;\n pointer-events: none;\n key-events: none;\n }\n`;\n\nconst MenuSectionList = styled.ul`\n list-style: none;\n margin: 0;\n overflow-y: unset !important;\n padding-inline-start: 0;\n\n ${UserMenuSectionListStyling}\n`;\n\nconst Top = styled.div`\n display: flex;\n flex-direction: row;\n align-items: center;\n padding: 22px 12px 0 12px;\n color: ${COLORS.neutral_600};\n\n h3 {\n margin-block-start: 0 !important;\n margin-block-end: 0 !important;\n margin-inline-start: 0px;\n margin-inline-end: 0px;\n margin-left: 24px;\n\n ${ComponentSStyling(ComponentTextStyle.Regular, 'inherit')}\n }\n`;\n\nconst LabelLine = styled.span`\n height: 32px;\n background-color: ${COLORS.neutral_20};\n padding-left: 24px;\n display: flex;\n line-height: 32px;\n`;\n\ninterface Props {\n header: string;\n elementsHeader: string;\n clickMenuAction: () => void;\n elements?: UserMenuItem[];\n}\n\nconst MobileSwitcherMenu = ({ header, elementsHeader, clickMenuAction, elements }: Props) => {\n React.useEffect(() => {\n function handleKeyPress(e: any) {\n if (e.keyCode === 27) {\n clickMenuAction();\n }\n }\n\n document.addEventListener('keydown', handleKeyPress, false);\n return () => {\n document.removeEventListener('keydown', handleKeyPress, false);\n };\n }, [clickMenuAction]);\n\n return (\n <Menu onClick={() => {}} role=\"menu\" aria-labelledby=\"UserMenuButton\">\n <Top>\n <IconButton variant=\"secondary\" shape=\"circular\" action={clickMenuAction} isInMobileMenu={true}>\n <ArrowLineLeft size=\"24px\" color={COLORS.neutral_600} />\n </IconButton>\n <h3>{header}</h3>\n <Right>\n <IconButton variant=\"secondary\" shape=\"circular\" action={clickMenuAction} isInMobileMenu={true}>\n <Close size=\"24px\" />\n </IconButton>\n </Right>\n </Top>\n {elements && elements?.length > 0 && (\n <MenuSection>\n <LabelLine>{elementsHeader}</LabelLine>\n <MenuSectionList>\n {elements?.map((element) => (\n <SwitcherMenuItem url={element?.to} label={element?.label} Icon={element.icon} />\n ))}\n </MenuSectionList>\n </MenuSection>\n )}\n </Menu>\n );\n};\n\nexport default MobileSwitcherMenu;\n"],"file":"MobileSwitcherMenu.js"}
1
+ {"version":3,"sources":["../../../src/Switcher/MobileSwitcherMenu.tsx"],"names":["React","styled","BREAKPOINTS","COLORS","ComponentTextStyle","scrollBarStyling","IconButton","ArrowLineLeft","Close","flowDown","Right","UserMenuSectionListStyling","SwitcherMenuItem","ComponentSStyling","Z_INDEXES","Menu","ul","white","off_canvas","SMALL","MenuSection","li","MenuSectionList","Top","div","neutral_600","Regular","LabelLine","span","neutral_20","MobileSwitcherMenu","header","elementsHeader","clickMenuAction","elements","useEffect","handleKeyPress","e","keyCode","document","addEventListener","removeEventListener","length","map","element","to","label","icon"],"mappings":";AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,OAAOC,MAAP,MAAmB,mBAAnB;AACA,SAAQC,WAAR,EAAqBC,MAArB,EAA6BC,kBAA7B,EAAiDC,gBAAjD,QAAwE,WAAxE;AAGA,SAAQC,UAAR,QAAyB,WAAzB;AACA,SAAQC,aAAR,EAAuBC,KAAvB,QAAmC,kCAAnC;AACA,SAAQC,QAAR,EAAkBC,KAAlB,EAAyBC,0BAAzB,QAA0D,4CAA1D;AACA,OAAOC,gBAAP,MAA6B,oBAA7B;AACA,SAAQC,iBAAR,QAAgC,sBAAhC;AACA,SAAQC,SAAR,QAAwB,qBAAxB;AAEA,MAAMC,IAAI,GAAGd,MAAM,CAACe,EAAG;AACvB;AACA;AACA,sBAAsBb,MAAM,CAACc,KAAM;AACnC;AACA;AACA,uBAAuBR,QAAS;AAChC,eAAeA,QAAS;AACxB;AACA;AACA,aAAaK,SAAS,CAACI,UAAW;AAClC;AACA;AACA;AACA;AACA,IAAIhB,WAAW,CAACiB,KAAM;AACtB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAId,gBAAiB;AACrB,CAzBA;AA2BA,MAAMe,WAAW,GAAGnB,MAAM,CAACoB,EAAG;AAC9B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CATA;AAWA,MAAMC,eAAe,GAAGrB,MAAM,CAACe,EAAG;AAClC;AACA;AACA;AACA;AACA;AACA,IAAIL,0BAA2B;AAC/B,CAPA;AASA,MAAMY,GAAG,GAAGtB,MAAM,CAACuB,GAAI;AACvB;AACA;AACA;AACA;AACA,WAAWrB,MAAM,CAACsB,WAAY;AAC9B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;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AAgC,IAAA,KAAK,EAAC,UAAtC;AAAiD,IAAA,MAAM,EAAEE,eAAzD;AAA0E,IAAA,cAAc,EAAE;AAA1F,kBACE,oBAAC,KAAD;AAAO,IAAA,IAAI,EAAC;AAAZ,IADF,CADF,CALF,CADF,EAYGC,QAAQ,IAAIA,QAAQ,EAAEQ,MAAV,GAAmB,CAA/B,iBACC,oBAAC,WAAD,qBACE,oBAAC,SAAD,QAAYV,cAAZ,CADF,eAEE,oBAAC,eAAD,QACGE,QAAQ,EAAES,GAAV,CAAeC,OAAD,iBACb,oBAAC,gBAAD;AAAkB,IAAA,GAAG,EAAEA,OAAO,EAAEC,EAAhC;AAAoC,IAAA,KAAK,EAAED,OAAO,EAAEE,KAApD;AAA2D,IAAA,IAAI,EAAEF,OAAO,CAACG;AAAzE,IADD,CADH,CAFF,CAbJ,CADF;AAyBD,CAvCD;;;AANEhB,EAAAA,M;AACAC,EAAAA,c;AACAC,EAAAA,e;AACAC,EAAAA,Q;;AA4CF,eAAeJ,kBAAf","sourcesContent":["import * as React from 'react';\nimport styled from 'styled-components';\nimport {BREAKPOINTS, COLORS, ComponentTextStyle, scrollBarStyling} from '../styles';\n\nimport {UserMenuItem} from '../types';\nimport {IconButton} from '../Button';\nimport {ArrowLineLeft, Close} from '../icons/systemicons/SystemIcons';\nimport {flowDown, Right, UserMenuSectionListStyling} from '../GlobalNavigationBar/mobile/CommonStyles';\nimport SwitcherMenuItem from './SwitcherMenuItem';\nimport {ComponentSStyling} from '../styles/typography';\nimport {Z_INDEXES} from '../styles/z-indexes';\n\nconst Menu = styled.ul`\n list-style: none;\n margin: 0;\n background-color: ${COLORS.white};\n box-sizing: border-box;\n display: none;\n -webkit-animation: ${flowDown} 0.2s ease-in-out;\n animation: ${flowDown} 0.2s ease-in-out;\n position: absolute;\n border-radius: 4px;\n z-index: ${Z_INDEXES.off_canvas};\n height: 100%;\n width: 320px;\n padding-inline-start: 0;\n overflow-y: scroll;\n ${BREAKPOINTS.SMALL} {\n min-width: 360px;\n }\n\n .open & {\n display: flex;\n flex-direction: column;\n }\n\n ${scrollBarStyling};\n`;\n\nconst MenuSection = styled.li`\n padding: 8px 0;\n position: relative;\n\n .disabled-link {\n color: #21212150;\n pointer-events: none;\n key-events: none;\n }\n`;\n\nconst MenuSectionList = styled.ul`\n list-style: none;\n margin: 0;\n overflow-y: unset !important;\n padding-inline-start: 0;\n\n ${UserMenuSectionListStyling}\n`;\n\nconst Top = styled.div`\n display: flex;\n flex-direction: row;\n align-items: center;\n padding: 22px 12px 0 12px;\n color: ${COLORS.neutral_600};\n\n h3 {\n margin-block-start: 0 !important;\n margin-block-end: 0 !important;\n margin-inline-start: 0px;\n margin-inline-end: 0px;\n margin-left: 24px;\n\n ${ComponentSStyling(ComponentTextStyle.Regular, 'inherit')}\n }\n`;\n\nconst LabelLine = styled.span`\n height: 32px;\n background-color: ${COLORS.neutral_20};\n padding-left: 24px;\n display: flex;\n line-height: 32px;\n`;\n\ninterface Props {\n header: string;\n elementsHeader: string;\n clickMenuAction: () => void;\n elements?: UserMenuItem[];\n}\n\nconst MobileSwitcherMenu = ({ header, elementsHeader, clickMenuAction, elements }: Props) => {\n React.useEffect(() => {\n function handleKeyPress(e: any) {\n if (e.keyCode === 27) {\n clickMenuAction();\n }\n }\n\n document.addEventListener('keydown', handleKeyPress, false);\n return () => {\n document.removeEventListener('keydown', handleKeyPress, false);\n };\n }, [clickMenuAction]);\n\n return (\n <Menu onClick={() => {}} role=\"menu\" aria-labelledby=\"UserMenuButton\">\n <Top>\n <IconButton variant=\"secondary\" shape=\"circular\" action={clickMenuAction} isInMobileMenu={true}>\n <ArrowLineLeft size=\"24px\" color={COLORS.neutral_600} />\n </IconButton>\n <h3>{header}</h3>\n <Right>\n <IconButton variant=\"secondary\" shape=\"circular\" action={clickMenuAction} isInMobileMenu={true}>\n <Close size=\"24px\" />\n </IconButton>\n </Right>\n </Top>\n {elements && elements?.length > 0 && (\n <MenuSection>\n <LabelLine>{elementsHeader}</LabelLine>\n <MenuSectionList>\n {elements?.map((element) => (\n <SwitcherMenuItem url={element?.to} label={element?.label} Icon={element.icon} />\n ))}\n </MenuSectionList>\n </MenuSection>\n )}\n </Menu>\n );\n};\n\nexport default MobileSwitcherMenu;\n"],"file":"MobileSwitcherMenu.js"}
@@ -2,6 +2,7 @@ import * as React from 'react';
2
2
  import styled from 'styled-components';
3
3
  import { COLORS, ComponentTextStyle } from '../styles';
4
4
  import { ComponentMStyling } from '../styles/typography';
5
+ import { Z_INDEXES } from '../styles/z-indexes';
5
6
  const StyledSwitcherItem = styled.div`
6
7
  padding: 16px 25px;
7
8
  margin: 0 2px;
@@ -32,6 +33,7 @@ const StyledSwitcherItem = styled.div`
32
33
  }
33
34
 
34
35
  &.active:not(.disabled) {
36
+ z-index: ${Z_INDEXES.active};
35
37
  font-weight: bold;
36
38
  color: ${COLORS.neutral_800};
37
39
 
@@ -50,6 +52,7 @@ const StyledSwitcherItem = styled.div`
50
52
  }
51
53
 
52
54
  &:hover:not(.disabled) {
55
+ z-index: ${Z_INDEXES.hover};
53
56
  color: ${COLORS.primary_600};
54
57
  background-color: ${COLORS.primary_20};
55
58
 
@@ -59,6 +62,7 @@ const StyledSwitcherItem = styled.div`
59
62
  }
60
63
 
61
64
  &:active:not(.disabled) {
65
+ z-index: ${Z_INDEXES.active};
62
66
  color: ${COLORS.primary_800};
63
67
  background-color: ${COLORS.primary_100};
64
68
  box-shadow: none;
@@ -73,6 +77,7 @@ const StyledSwitcherItem = styled.div`
73
77
  }
74
78
 
75
79
  &:focus:not(.disabled) {
80
+ z-index: ${Z_INDEXES.focus};
76
81
  box-shadow: 0px 0px 8px ${COLORS.primary_500}, 0px 4px 12px rgba(46, 127, 161, 0.25);
77
82
  outline: none;
78
83
  }