@webiny/ui 5.43.2 → 6.0.0-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (575) hide show
  1. package/Accordion/Accordion.d.ts +7 -3
  2. package/Accordion/Accordion.js +9 -30
  3. package/Accordion/Accordion.js.map +1 -1
  4. package/Accordion/AccordionItem.d.ts +116 -37
  5. package/Accordion/AccordionItem.js +33 -188
  6. package/Accordion/AccordionItem.js.map +1 -1
  7. package/Accordion/AccordionItemActions.d.ts +8 -0
  8. package/Accordion/AccordionItemActions.js +30 -28
  9. package/Accordion/AccordionItemActions.js.map +1 -1
  10. package/Accordion/index.js +2 -27
  11. package/Accordion/index.js.map +1 -1
  12. package/Alert/Alert.d.ts +2 -1
  13. package/Alert/Alert.js +16 -52
  14. package/Alert/Alert.js.map +1 -1
  15. package/Alert/index.js +1 -16
  16. package/Alert/index.js.map +1 -1
  17. package/AutoComplete/AutoComplete.d.ts +6 -18
  18. package/AutoComplete/AutoComplete.js +61 -289
  19. package/AutoComplete/AutoComplete.js.map +1 -1
  20. package/AutoComplete/MultiAutoComplete.d.ts +12 -46
  21. package/AutoComplete/MultiAutoComplete.js +78 -563
  22. package/AutoComplete/MultiAutoComplete.js.map +1 -1
  23. package/AutoComplete/index.js +2 -27
  24. package/AutoComplete/index.js.map +1 -1
  25. package/AutoComplete/types.d.ts +4 -4
  26. package/AutoComplete/types.js +1 -5
  27. package/AutoComplete/types.js.map +1 -1
  28. package/AutoComplete/utils.d.ts +1 -1
  29. package/AutoComplete/utils.js +4 -10
  30. package/AutoComplete/utils.js.map +1 -1
  31. package/Avatar/Avatar.d.ts +2 -1
  32. package/Avatar/Avatar.js +30 -81
  33. package/Avatar/Avatar.js.map +1 -1
  34. package/Avatar/index.js +1 -16
  35. package/Avatar/index.js.map +1 -1
  36. package/Button/Button.d.ts +8 -27
  37. package/Button/Button.js +12 -121
  38. package/Button/Button.js.map +1 -1
  39. package/Button/ButtonDefault.d.ts +7 -0
  40. package/Button/ButtonDefault.js +16 -0
  41. package/Button/ButtonDefault.js.map +1 -0
  42. package/Button/ButtonFloating.d.ts +7 -0
  43. package/Button/ButtonFloating.js +12 -0
  44. package/Button/ButtonFloating.js.map +1 -0
  45. package/Button/ButtonIcon.d.ts +9 -0
  46. package/Button/ButtonIcon.js +11 -0
  47. package/Button/ButtonIcon.js.map +1 -0
  48. package/Button/ButtonPrimary.d.ts +7 -0
  49. package/Button/ButtonPrimary.js +16 -0
  50. package/Button/ButtonPrimary.js.map +1 -0
  51. package/Button/ButtonSecondary.d.ts +7 -0
  52. package/Button/ButtonSecondary.js +16 -0
  53. package/Button/ButtonSecondary.js.map +1 -0
  54. package/Button/CopyButton.d.ts +17 -0
  55. package/Button/CopyButton.js +12 -0
  56. package/Button/CopyButton.js.map +1 -0
  57. package/Button/IconButton.d.ts +16 -0
  58. package/Button/IconButton.js +15 -0
  59. package/Button/IconButton.js.map +1 -0
  60. package/Button/index.d.ts +7 -2
  61. package/Button/index.js +8 -38
  62. package/Button/index.js.map +1 -1
  63. package/Button/useMappedButtonProps.d.ts +14 -0
  64. package/Button/useMappedButtonProps.js +21 -0
  65. package/Button/useMappedButtonProps.js.map +1 -0
  66. package/Carousel/Carousel.d.ts +6 -15
  67. package/Carousel/Carousel.js +10 -42
  68. package/Carousel/Carousel.js.map +1 -1
  69. package/Carousel/index.js +1 -13
  70. package/Carousel/index.js.map +1 -1
  71. package/Checkbox/Checkbox.d.ts +3 -5
  72. package/Checkbox/Checkbox.js +32 -64
  73. package/Checkbox/Checkbox.js.map +1 -1
  74. package/Checkbox/CheckboxGroup.d.ts +5 -1
  75. package/Checkbox/CheckboxGroup.js +46 -58
  76. package/Checkbox/CheckboxGroup.js.map +1 -1
  77. package/Checkbox/index.js +2 -20
  78. package/Checkbox/index.js.map +1 -1
  79. package/Chips/Chip.d.ts +31 -2
  80. package/Chips/Chip.js +44 -27
  81. package/Chips/Chip.js.map +1 -1
  82. package/Chips/Chips.d.ts +4 -0
  83. package/Chips/Chips.js +14 -21
  84. package/Chips/Chips.js.map +1 -1
  85. package/Chips/index.js +2 -27
  86. package/Chips/index.js.map +1 -1
  87. package/CodeEditor/CodeEditor.d.ts +4 -12
  88. package/CodeEditor/CodeEditor.js +12 -82
  89. package/CodeEditor/CodeEditor.js.map +1 -1
  90. package/CodeEditor/index.js +1 -16
  91. package/CodeEditor/index.js.map +1 -1
  92. package/ColorPicker/ColorPicker.d.ts +4 -19
  93. package/ColorPicker/ColorPicker.js +25 -150
  94. package/ColorPicker/ColorPicker.js.map +1 -1
  95. package/ColorPicker/index.js +1 -16
  96. package/ColorPicker/index.js.map +1 -1
  97. package/ConfirmationDialog/ConfirmationDialog.js +78 -102
  98. package/ConfirmationDialog/ConfirmationDialog.js.map +1 -1
  99. package/ConfirmationDialog/index.js +2 -27
  100. package/ConfirmationDialog/index.js.map +1 -1
  101. package/ConfirmationDialog/withConfirmation.js +10 -18
  102. package/ConfirmationDialog/withConfirmation.js.map +1 -1
  103. package/DataTable/DataTable.d.ts +54 -91
  104. package/DataTable/DataTable.js +56 -324
  105. package/DataTable/DataTable.js.map +1 -1
  106. package/DataTable/index.js +1 -16
  107. package/DataTable/index.js.map +1 -1
  108. package/DateTime/Date.js +14 -21
  109. package/DateTime/Date.js.map +1 -1
  110. package/DateTime/index.js +1 -12
  111. package/DateTime/index.js.map +1 -1
  112. package/DelayedOnChange/index.d.ts +7 -1
  113. package/DelayedOnChange/index.js +7 -16
  114. package/DelayedOnChange/index.js.map +1 -1
  115. package/Dialog/Dialog.d.ts +47 -59
  116. package/Dialog/Dialog.js +69 -79
  117. package/Dialog/Dialog.js.map +1 -1
  118. package/Dialog/index.js +1 -16
  119. package/Dialog/index.js.map +1 -1
  120. package/Drawer/Drawer.d.ts +28 -21
  121. package/Drawer/Drawer.js +42 -52
  122. package/Drawer/Drawer.js.map +1 -1
  123. package/Drawer/index.js +1 -16
  124. package/Drawer/index.js.map +1 -1
  125. package/DynamicFieldset/index.d.ts +7 -1
  126. package/DynamicFieldset/index.js +7 -13
  127. package/DynamicFieldset/index.js.map +1 -1
  128. package/Elevation/Elevation.d.ts +6 -2
  129. package/Elevation/Elevation.js +13 -15
  130. package/Elevation/Elevation.js.map +1 -1
  131. package/Elevation/index.js +1 -16
  132. package/Elevation/index.js.map +1 -1
  133. package/FormElementMessage/FormElementMessage.d.ts +6 -2
  134. package/FormElementMessage/FormElementMessage.js +21 -16
  135. package/FormElementMessage/FormElementMessage.js.map +1 -1
  136. package/FormElementMessage/index.js +1 -12
  137. package/FormElementMessage/index.js.map +1 -1
  138. package/FullName/FullName.d.ts +4 -0
  139. package/FullName/FullName.js +11 -9
  140. package/FullName/FullName.js.map +1 -1
  141. package/FullName/index.js +1 -16
  142. package/FullName/index.js.map +1 -1
  143. package/Grid/Grid.d.ts +32 -8
  144. package/Grid/Grid.js +37 -16
  145. package/Grid/Grid.js.map +1 -1
  146. package/Grid/index.js +1 -16
  147. package/Grid/index.js.map +1 -1
  148. package/Helpers/ClassNames.d.ts +3 -3
  149. package/Helpers/ClassNames.js +13 -19
  150. package/Helpers/ClassNames.js.map +1 -1
  151. package/Helpers/index.js +2 -12
  152. package/Helpers/index.js.map +1 -1
  153. package/Icon/Icon.d.ts +7 -2
  154. package/Icon/Icon.js +9 -25
  155. package/Icon/Icon.js.map +1 -1
  156. package/Icon/index.js +1 -16
  157. package/Icon/index.js.map +1 -1
  158. package/Image/index.d.ts +6 -1
  159. package/Image/index.js +6 -15
  160. package/Image/index.js.map +1 -1
  161. package/ImageEditor/ImageEditor.d.ts +8 -23
  162. package/ImageEditor/ImageEditor.js +11 -266
  163. package/ImageEditor/ImageEditor.js.map +1 -1
  164. package/ImageEditor/index.js +1 -16
  165. package/ImageEditor/index.js.map +1 -1
  166. package/ImageUpload/Image.d.ts +8 -15
  167. package/ImageUpload/Image.js +12 -114
  168. package/ImageUpload/Image.js.map +1 -1
  169. package/ImageUpload/ImageEditorDialog.d.ts +5 -1
  170. package/ImageUpload/ImageEditorDialog.js +11 -79
  171. package/ImageUpload/ImageEditorDialog.js.map +1 -1
  172. package/ImageUpload/MultiImageUpload.d.ts +6 -21
  173. package/ImageUpload/MultiImageUpload.js +12 -278
  174. package/ImageUpload/MultiImageUpload.js.map +1 -1
  175. package/ImageUpload/SingleImageUpload.d.ts +5 -22
  176. package/ImageUpload/SingleImageUpload.js +12 -189
  177. package/ImageUpload/SingleImageUpload.js.map +1 -1
  178. package/ImageUpload/index.d.ts +1 -1
  179. package/ImageUpload/index.js +4 -34
  180. package/ImageUpload/index.js.map +1 -1
  181. package/Input/Input.d.ts +59 -8
  182. package/Input/Input.js +70 -73
  183. package/Input/Input.js.map +1 -1
  184. package/Input/index.js +1 -16
  185. package/Input/index.js.map +1 -1
  186. package/List/CollapsibleList/index.d.ts +18 -4
  187. package/List/CollapsibleList/index.js +9 -13
  188. package/List/CollapsibleList/index.js.map +1 -1
  189. package/List/DataList/DataList.d.ts +12 -38
  190. package/List/DataList/DataList.js +15 -305
  191. package/List/DataList/DataList.js.map +1 -1
  192. package/List/DataList/DataListModalOverlay/index.d.ts +12 -3
  193. package/List/DataList/DataListModalOverlay/index.js +13 -31
  194. package/List/DataList/DataListModalOverlay/index.js.map +1 -1
  195. package/List/DataList/DataListWithSections.d.ts +12 -36
  196. package/List/DataList/DataListWithSections.js +15 -323
  197. package/List/DataList/DataListWithSections.js.map +1 -1
  198. package/List/DataList/icons/index.d.ts +1 -15
  199. package/List/DataList/icons/index.js +1 -62
  200. package/List/DataList/icons/index.js.map +1 -1
  201. package/List/DataList/index.d.ts +0 -1
  202. package/List/DataList/index.js +3 -58
  203. package/List/DataList/index.js.map +1 -1
  204. package/List/DataList/types.d.ts +1 -28
  205. package/List/DataList/types.js +1 -5
  206. package/List/DataList/types.js.map +1 -1
  207. package/List/List/List.d.ts +51 -0
  208. package/List/List/List.js +16 -0
  209. package/List/List/List.js.map +1 -0
  210. package/List/List/ListItem.d.ts +61 -0
  211. package/List/List/ListItem.js +91 -0
  212. package/List/List/ListItem.js.map +1 -0
  213. package/List/List/ListItemAction.d.ts +9 -0
  214. package/List/List/ListItemAction.js +15 -0
  215. package/List/List/ListItemAction.js.map +1 -0
  216. package/List/List/ListItemGraphic.d.ts +18 -0
  217. package/List/List/ListItemGraphic.js +26 -0
  218. package/List/List/ListItemGraphic.js.map +1 -0
  219. package/List/List/ListItemMeta.d.ts +26 -0
  220. package/List/List/ListItemMeta.js +24 -0
  221. package/List/List/ListItemMeta.js.map +1 -0
  222. package/List/List/ListItemText.d.ts +42 -0
  223. package/List/List/ListItemText.js +51 -0
  224. package/List/List/ListItemText.js.map +1 -0
  225. package/List/List/index.d.ts +6 -0
  226. package/List/List/index.js +8 -0
  227. package/List/List/index.js.map +1 -0
  228. package/List/index.d.ts +1 -0
  229. package/List/index.js +4 -70
  230. package/List/index.js.map +1 -1
  231. package/Menu/Menu.d.ts +40 -4
  232. package/Menu/Menu.js +74 -100
  233. package/Menu/Menu.js.map +1 -1
  234. package/Menu/index.js +1 -16
  235. package/Menu/index.js.map +1 -1
  236. package/Mosaic/Mosaic.d.ts +5 -5
  237. package/Mosaic/Mosaic.js +6 -26
  238. package/Mosaic/Mosaic.js.map +1 -1
  239. package/Mosaic/index.js +1 -16
  240. package/Mosaic/index.js.map +1 -1
  241. package/Progress/CircularProgress.d.ts +10 -2
  242. package/Progress/CircularProgress.js +16 -67
  243. package/Progress/CircularProgress.js.map +1 -1
  244. package/Progress/index.d.ts +1 -1
  245. package/Progress/index.js +1 -13
  246. package/Progress/index.js.map +1 -1
  247. package/Radio/Radio.d.ts +3 -3
  248. package/Radio/Radio.js +34 -54
  249. package/Radio/Radio.js.map +1 -1
  250. package/Radio/RadioGroup.d.ts +6 -2
  251. package/Radio/RadioGroup.js +37 -48
  252. package/Radio/RadioGroup.js.map +1 -1
  253. package/Radio/index.js +2 -20
  254. package/Radio/index.js.map +1 -1
  255. package/RichTextEditor/RichTextEditor.d.ts +10 -29
  256. package/RichTextEditor/RichTextEditor.js +14 -131
  257. package/RichTextEditor/RichTextEditor.js.map +1 -1
  258. package/RichTextEditor/index.d.ts +3 -2
  259. package/RichTextEditor/index.js +2 -27
  260. package/RichTextEditor/index.js.map +1 -1
  261. package/Ripple/Ripple.d.ts +1 -1
  262. package/Ripple/Ripple.js +6 -15
  263. package/Ripple/Ripple.js.map +1 -1
  264. package/Ripple/index.js +1 -16
  265. package/Ripple/index.js.map +1 -1
  266. package/Scrollbar/Scrollbar.d.ts +5 -8
  267. package/Scrollbar/Scrollbar.js +7 -11
  268. package/Scrollbar/Scrollbar.js.map +1 -1
  269. package/Scrollbar/index.js +1 -16
  270. package/Scrollbar/index.js.map +1 -1
  271. package/Section/index.d.ts +4 -0
  272. package/Section/index.js +13 -66
  273. package/Section/index.js.map +1 -1
  274. package/Select/Select.d.ts +36 -3
  275. package/Select/Select.js +91 -90
  276. package/Select/Select.js.map +1 -1
  277. package/Select/index.js +1 -16
  278. package/Select/index.js.map +1 -1
  279. package/Skeleton/Skeleton.d.ts +24 -6
  280. package/Skeleton/Skeleton.js +16 -20
  281. package/Skeleton/Skeleton.js.map +1 -1
  282. package/Skeleton/index.js +1 -16
  283. package/Skeleton/index.js.map +1 -1
  284. package/Slider/Slider.d.ts +7 -13
  285. package/Slider/Slider.js +47 -81
  286. package/Slider/Slider.js.map +1 -1
  287. package/Slider/index.js +1 -13
  288. package/Slider/index.js.map +1 -1
  289. package/Snackbar/Snackbar.d.ts +44 -8
  290. package/Snackbar/Snackbar.js +27 -44
  291. package/Snackbar/Snackbar.js.map +1 -1
  292. package/Snackbar/index.js +1 -18
  293. package/Snackbar/index.js.map +1 -1
  294. package/Switch/Switch.d.ts +18 -3
  295. package/Switch/Switch.js +25 -47
  296. package/Switch/Switch.js.map +1 -1
  297. package/Switch/index.js +1 -16
  298. package/Switch/index.js.map +1 -1
  299. package/Tabs/Tab.d.ts +23 -2
  300. package/Tabs/Tab.js +16 -20
  301. package/Tabs/Tab.js.map +1 -1
  302. package/Tabs/Tabs.d.ts +12 -7
  303. package/Tabs/Tabs.js +56 -110
  304. package/Tabs/Tabs.js.map +1 -1
  305. package/Tabs/index.js +2 -27
  306. package/Tabs/index.js.map +1 -1
  307. package/Tags/Tags.d.ts +1 -1
  308. package/Tags/Tags.js +31 -83
  309. package/Tags/Tags.js.map +1 -1
  310. package/Tags/index.js +1 -16
  311. package/Tags/index.js.map +1 -1
  312. package/TimeAgo/index.d.ts +6 -2
  313. package/TimeAgo/index.js +6 -13
  314. package/TimeAgo/index.js.map +1 -1
  315. package/Tooltip/Tooltip.d.ts +4 -16
  316. package/Tooltip/Tooltip.js +61 -49
  317. package/Tooltip/Tooltip.js.map +1 -1
  318. package/Tooltip/index.js +1 -16
  319. package/Tooltip/index.js.map +1 -1
  320. package/TopAppBar/TopAppBar.d.ts +25 -1
  321. package/TopAppBar/TopAppBar.js +34 -14
  322. package/TopAppBar/TopAppBar.js.map +1 -1
  323. package/TopAppBar/TopAppBarActionItem.d.ts +5 -3
  324. package/TopAppBar/TopAppBarActionItem.js +10 -11
  325. package/TopAppBar/TopAppBarActionItem.js.map +1 -1
  326. package/TopAppBar/TopAppBarNavigationIcon.d.ts +5 -3
  327. package/TopAppBar/TopAppBarNavigationIcon.js +10 -11
  328. package/TopAppBar/TopAppBarNavigationIcon.js.map +1 -1
  329. package/TopAppBar/TopAppBarPrimary.d.ts +4 -0
  330. package/TopAppBar/TopAppBarPrimary.js +13 -15
  331. package/TopAppBar/TopAppBarPrimary.js.map +1 -1
  332. package/TopAppBar/TopAppBarSecondary.d.ts +4 -0
  333. package/TopAppBar/TopAppBarSecondary.js +14 -17
  334. package/TopAppBar/TopAppBarSecondary.js.map +1 -1
  335. package/TopAppBar/TopAppBarSection.d.ts +10 -1
  336. package/TopAppBar/TopAppBarSection.js +8 -15
  337. package/TopAppBar/TopAppBarSection.js.map +1 -1
  338. package/TopAppBar/TopAppBarTitle.d.ts +6 -3
  339. package/TopAppBar/TopAppBarTitle.js +9 -15
  340. package/TopAppBar/TopAppBarTitle.js.map +1 -1
  341. package/TopAppBar/index.js +7 -82
  342. package/TopAppBar/index.js.map +1 -1
  343. package/Typography/Typography.d.ts +8 -3
  344. package/Typography/Typography.js +32 -12
  345. package/Typography/Typography.js.map +1 -1
  346. package/Typography/index.js +1 -16
  347. package/Typography/index.js.map +1 -1
  348. package/package.json +9 -63
  349. package/styles.scss +15 -41
  350. package/types.js +1 -5
  351. package/Accordion/README.md +0 -11
  352. package/Accordion/icons/round-keyboard_arrow_down-24px.svg +0 -16
  353. package/Accordion/icons/round-keyboard_arrow_up-24px.svg +0 -16
  354. package/Accordion/icons/round-settings-24px.svg +0 -21
  355. package/Alert/README.md +0 -11
  356. package/AutoComplete/AutoCompleteReadme.md +0 -11
  357. package/AutoComplete/MultiAutoCompleteReadme.md +0 -11
  358. package/AutoComplete/icons/baseline-close-24px.svg +0 -4
  359. package/AutoComplete/icons/delete.svg +0 -12
  360. package/AutoComplete/icons/navigate_before-24px.svg +0 -1
  361. package/AutoComplete/icons/navigate_next-24px.svg +0 -1
  362. package/AutoComplete/icons/reorder_black_24dp.svg +0 -1
  363. package/AutoComplete/icons/skip_next-24px.svg +0 -1
  364. package/AutoComplete/icons/skip_previous-24px.svg +0 -1
  365. package/AutoComplete/icons/spinner.svg +0 -3
  366. package/AutoComplete/styles.d.ts +0 -2
  367. package/AutoComplete/styles.js +0 -66
  368. package/AutoComplete/styles.js.map +0 -1
  369. package/Avatar/README.md +0 -11
  370. package/Button/Button.styles.d.ts +0 -6
  371. package/Button/Button.styles.js +0 -17
  372. package/Button/Button.styles.js.map +0 -1
  373. package/Button/CopyButton/CopyButton.d.ts +0 -11
  374. package/Button/CopyButton/CopyButton.js +0 -33
  375. package/Button/CopyButton/CopyButton.js.map +0 -1
  376. package/Button/CopyButton/README.md +0 -11
  377. package/Button/IconButton/IconButton.d.ts +0 -37
  378. package/Button/IconButton/IconButton.js +0 -49
  379. package/Button/IconButton/IconButton.js.map +0 -1
  380. package/Button/IconButton/README.md +0 -15
  381. package/Button/README.md +0 -28
  382. package/Button/assets/baseline-cloud_done-24px.svg +0 -3
  383. package/Button/assets/file_copy-24px.svg +0 -1
  384. package/Button/assets/round-more_vert-24px.svg +0 -12
  385. package/Carousel/README.md +0 -15
  386. package/Checkbox/Checkbox.styles.d.ts +0 -6
  387. package/Checkbox/Checkbox.styles.js +0 -21
  388. package/Checkbox/Checkbox.styles.js.map +0 -1
  389. package/Checkbox/README_Checkbox.md +0 -15
  390. package/Checkbox/README_CheckboxGroup.md +0 -19
  391. package/Chips/README.md +0 -15
  392. package/Chips/icons/baseline-done-24px.svg +0 -4
  393. package/Chips/icons/baseline-email-24px.svg +0 -3
  394. package/Chips/styles.d.ts +0 -2
  395. package/Chips/styles.js +0 -25
  396. package/Chips/styles.js.map +0 -1
  397. package/CodeEditor/README.md +0 -21
  398. package/ColorPicker/README.md +0 -11
  399. package/ConfirmationDialog/README.md +0 -11
  400. package/DataTable/ColumnDirection.d.ts +0 -5
  401. package/DataTable/ColumnDirection.js +0 -19
  402. package/DataTable/ColumnDirection.js.map +0 -1
  403. package/DataTable/ColumnsVisibility.d.ts +0 -7
  404. package/DataTable/ColumnsVisibility.js +0 -64
  405. package/DataTable/ColumnsVisibility.js.map +0 -1
  406. package/DataTable/README.md +0 -72
  407. package/DataTable/styled.d.ts +0 -41
  408. package/DataTable/styled.js +0 -126
  409. package/DataTable/styled.js.map +0 -1
  410. package/DelayedOnChange/DelayedOnChange.d.ts +0 -39
  411. package/DelayedOnChange/DelayedOnChange.js +0 -132
  412. package/DelayedOnChange/DelayedOnChange.js.map +0 -1
  413. package/Dialog/README.md +0 -23
  414. package/Drawer/README.md +0 -15
  415. package/DynamicFieldset/Fieldset.d.ts +0 -51
  416. package/DynamicFieldset/Fieldset.js +0 -139
  417. package/DynamicFieldset/Fieldset.js.map +0 -1
  418. package/Elevation/README.md +0 -15
  419. package/FullName/README.md +0 -11
  420. package/Grid/README.md +0 -15
  421. package/Icon/README.md +0 -11
  422. package/Icon/svg/baseline-autorenew-24px.svg +0 -4
  423. package/Icon/svg/baseline-cloud_done-24px.svg +0 -4
  424. package/Icon/svg/baseline-delete-24px.svg +0 -4
  425. package/Icon/svg/baseline-done-24px.svg +0 -4
  426. package/Image/Image.d.ts +0 -6
  427. package/Image/Image.js +0 -25
  428. package/Image/Image.js.map +0 -1
  429. package/Image/README.md +0 -12
  430. package/ImageEditor/toolbar/crop.d.ts +0 -4
  431. package/ImageEditor/toolbar/crop.js +0 -74
  432. package/ImageEditor/toolbar/crop.js.map +0 -1
  433. package/ImageEditor/toolbar/filter.d.ts +0 -3
  434. package/ImageEditor/toolbar/filter.js +0 -208
  435. package/ImageEditor/toolbar/filter.js.map +0 -1
  436. package/ImageEditor/toolbar/flip.d.ts +0 -4
  437. package/ImageEditor/toolbar/flip.js +0 -99
  438. package/ImageEditor/toolbar/flip.js.map +0 -1
  439. package/ImageEditor/toolbar/icons/crop.svg +0 -4
  440. package/ImageEditor/toolbar/icons/draw.svg +0 -4
  441. package/ImageEditor/toolbar/icons/filter.svg +0 -4
  442. package/ImageEditor/toolbar/icons/flip.svg +0 -4
  443. package/ImageEditor/toolbar/icons/index.d.ts +0 -8
  444. package/ImageEditor/toolbar/icons/index.js +0 -63
  445. package/ImageEditor/toolbar/icons/index.js.map +0 -1
  446. package/ImageEditor/toolbar/icons/redo.svg +0 -4
  447. package/ImageEditor/toolbar/icons/rotateLeft.svg +0 -4
  448. package/ImageEditor/toolbar/icons/rotateRight.svg +0 -4
  449. package/ImageEditor/toolbar/icons/undo.svg +0 -4
  450. package/ImageEditor/toolbar/index.d.ts +0 -4
  451. package/ImageEditor/toolbar/index.js +0 -36
  452. package/ImageEditor/toolbar/index.js.map +0 -1
  453. package/ImageEditor/toolbar/rotate.d.ts +0 -4
  454. package/ImageEditor/toolbar/rotate.js +0 -127
  455. package/ImageEditor/toolbar/rotate.js.map +0 -1
  456. package/ImageEditor/toolbar/types.d.ts +0 -32
  457. package/ImageEditor/toolbar/types.js +0 -7
  458. package/ImageEditor/toolbar/types.js.map +0 -1
  459. package/ImageUpload/README.md +0 -11
  460. package/ImageUpload/icons/round-add_photo_alternate-24px.svg +0 -23
  461. package/ImageUpload/icons/round-close-24px.svg +0 -13
  462. package/ImageUpload/icons/round-edit-24px.svg +0 -4
  463. package/ImageUpload/image.jpeg +0 -0
  464. package/ImageUpload/styled.d.ts +0 -27
  465. package/ImageUpload/styled.js +0 -120
  466. package/ImageUpload/styled.js.map +0 -1
  467. package/Input/README.md +0 -16
  468. package/Input/__tests__/Input.test.d.ts +0 -1
  469. package/Input/__tests__/Input.test.js +0 -103
  470. package/Input/__tests__/Input.test.js.map +0 -1
  471. package/Input/styled.d.ts +0 -4
  472. package/Input/styled.js +0 -16
  473. package/Input/styled.js.map +0 -1
  474. package/Input/svg/baseline-autorenew-24px.svg +0 -4
  475. package/Input/svg/baseline-cloud_done-24px.svg +0 -4
  476. package/Input/svg/baseline-delete-24px.svg +0 -4
  477. package/Input/svg/baseline-done-24px.svg +0 -4
  478. package/List/CollapsibleList/README.md +0 -11
  479. package/List/CollapsibleList/index.css +0 -31
  480. package/List/DataList/DataListModalOverlay/DataListModalOverlay.d.ts +0 -20
  481. package/List/DataList/DataListModalOverlay/DataListModalOverlay.js +0 -99
  482. package/List/DataList/DataListModalOverlay/DataListModalOverlay.js.map +0 -1
  483. package/List/DataList/DataListModalOverlay/DataListModalOverlayAction.d.ts +0 -6
  484. package/List/DataList/DataListModalOverlay/DataListModalOverlayAction.js +0 -29
  485. package/List/DataList/DataListModalOverlay/DataListModalOverlayAction.js.map +0 -1
  486. package/List/DataList/DataListModalOverlay/DataListModalOverlayContext.d.ts +0 -11
  487. package/List/DataList/DataListModalOverlay/DataListModalOverlayContext.js +0 -30
  488. package/List/DataList/DataListModalOverlay/DataListModalOverlayContext.js.map +0 -1
  489. package/List/DataList/Loader.d.ts +0 -3
  490. package/List/DataList/Loader.js +0 -105
  491. package/List/DataList/Loader.js.map +0 -1
  492. package/List/DataList/NoData.d.ts +0 -3
  493. package/List/DataList/NoData.js +0 -33
  494. package/List/DataList/NoData.js.map +0 -1
  495. package/List/DataList/README.md +0 -17
  496. package/List/DataList/icons/baseline-autorenew-24px.svg +0 -4
  497. package/List/DataList/icons/baseline-delete-24px.svg +0 -4
  498. package/List/DataList/icons/baseline-edit-24px.svg +0 -4
  499. package/List/DataList/icons/baseline-navigate_before-24px.svg +0 -4
  500. package/List/DataList/icons/baseline-navigate_next-24px.svg +0 -4
  501. package/List/DataList/icons/baseline-sort-24px.svg +0 -4
  502. package/List/DataList/icons/baseline-tune-24px.svg +0 -4
  503. package/List/DataList/icons/filter_alt-24px.svg +0 -1
  504. package/List/DataList/icons/round-more_vert-24px.svg +0 -12
  505. package/List/List.d.ts +0 -131
  506. package/List/List.js +0 -148
  507. package/List/List.js.map +0 -1
  508. package/List/README.md +0 -22
  509. package/List/icons/baseline-autorenew-24px.svg +0 -4
  510. package/List/icons/baseline-cloud_done-24px.svg +0 -4
  511. package/List/icons/baseline-delete-24px.svg +0 -4
  512. package/List/icons/baseline-done-24px.svg +0 -4
  513. package/List/icons/baseline-email-24px.svg +0 -4
  514. package/List/icons/index.d.ts +0 -3
  515. package/List/icons/index.js +0 -22
  516. package/List/icons/index.js.map +0 -1
  517. package/List/styled.d.ts +0 -6
  518. package/List/styled.js +0 -29
  519. package/List/styled.js.map +0 -1
  520. package/Menu/README.md +0 -15
  521. package/Mosaic/README.md +0 -15
  522. package/Progress/README.md +0 -19
  523. package/Progress/svg/circularProgress.svg +0 -3
  524. package/Radio/README.md +0 -17
  525. package/Radio/Radio.styles.d.ts +0 -6
  526. package/Radio/Radio.styles.js +0 -21
  527. package/Radio/Radio.styles.js.map +0 -1
  528. package/RichTextEditor/README.md +0 -10
  529. package/RichTextEditor/createPropsFromConfig.d.ts +0 -15
  530. package/RichTextEditor/createPropsFromConfig.js +0 -30
  531. package/RichTextEditor/createPropsFromConfig.js.map +0 -1
  532. package/Ripple/README.md +0 -15
  533. package/Ripple/svg/baseline-autorenew-24px.svg +0 -4
  534. package/Ripple/svg/baseline-cloud_done-24px.svg +0 -4
  535. package/Ripple/svg/baseline-delete-24px.svg +0 -4
  536. package/Ripple/svg/baseline-done-24px.svg +0 -4
  537. package/Scrollbar/README.md +0 -15
  538. package/Section/README.md +0 -11
  539. package/Select/README.md +0 -15
  540. package/Select/styled.d.ts +0 -8
  541. package/Select/styled.js +0 -21
  542. package/Select/styled.js.map +0 -1
  543. package/Skeleton/README.md +0 -21
  544. package/Slider/README.md +0 -15
  545. package/Snackbar/README.md +0 -15
  546. package/Switch/README.md +0 -15
  547. package/Tabs/svg/baseline-autorenew-24px.svg +0 -4
  548. package/Tabs/svg/baseline-cloud_done-24px.svg +0 -4
  549. package/Tabs/svg/baseline-delete-24px.svg +0 -4
  550. package/Tabs/svg/baseline-done-24px.svg +0 -4
  551. package/Tags/README.md +0 -15
  552. package/Tags/icons/baseline-close-24px.svg +0 -4
  553. package/Tooltip/README.md +0 -15
  554. package/Tooltip/style.scss +0 -97
  555. package/TopAppBar/README.md +0 -20
  556. package/TopAppBar/icons/baseline-autorenew-24px.svg +0 -4
  557. package/TopAppBar/icons/baseline-cloud_done-24px.svg +0 -4
  558. package/TopAppBar/icons/baseline-delete-24px.svg +0 -4
  559. package/TopAppBar/icons/baseline-email-24px.svg +0 -4
  560. package/TopAppBar/icons/baseline-menu-24px.svg +0 -4
  561. package/TopProgressBar/README.md +0 -11
  562. package/TopProgressBar/TopProgressBar.d.ts +0 -15
  563. package/TopProgressBar/TopProgressBar.js +0 -18
  564. package/TopProgressBar/TopProgressBar.js.map +0 -1
  565. package/TopProgressBar/hoc/index.d.ts +0 -1
  566. package/TopProgressBar/hoc/index.js +0 -15
  567. package/TopProgressBar/hoc/index.js.map +0 -1
  568. package/TopProgressBar/hoc/withTopProgressBar.d.ts +0 -3
  569. package/TopProgressBar/hoc/withTopProgressBar.js +0 -29
  570. package/TopProgressBar/hoc/withTopProgressBar.js.map +0 -1
  571. package/TopProgressBar/index.d.ts +0 -1
  572. package/TopProgressBar/index.js +0 -18
  573. package/TopProgressBar/index.js.map +0 -1
  574. package/TopProgressBar/style.scss +0 -21
  575. package/Typography/README.md +0 -15
@@ -0,0 +1,51 @@
1
+ import { useContext, useEffect } from "react";
2
+ import { DeprecatedListItemContext } from "./..";
3
+
4
+ /** Text Wrapper for the ListItem */
5
+
6
+ /**
7
+ * @deprecated This component is deprecated and will be removed in future releases.
8
+ * Please find out the new `ListItem` component props from the `@webiny/admin-ui` package instead.
9
+ */
10
+ export const ListItemText = props => {
11
+ const listItemContext = useContext(DeprecatedListItemContext);
12
+ useEffect(() => {
13
+ props.onClick && listItemContext.addOnClickCallback(props.onClick);
14
+ }, [props]);
15
+ return props.children;
16
+ };
17
+ /**
18
+ * @deprecated This component is deprecated and will be removed in future releases.
19
+ * Please find out the new `ListItem` component props from the `@webiny/admin-ui` package instead.
20
+ */
21
+ export const ListItemTextPrimary = props => {
22
+ const listItemContext = useContext(DeprecatedListItemContext);
23
+ useEffect(() => {
24
+ listItemContext.addTitle(props.children);
25
+ }, [props]);
26
+ return null;
27
+ };
28
+ /**
29
+ * @deprecated This component is deprecated and will be removed in future releases.
30
+ * Please find out the new `ListItem` component props from the `@webiny/admin-ui` package instead.
31
+ */
32
+ export const ListItemTextSecondary = props => {
33
+ const listItemContext = useContext(DeprecatedListItemContext);
34
+ useEffect(() => {
35
+ listItemContext.addDescription(props.children);
36
+ }, [props]);
37
+ return null;
38
+ };
39
+ /**
40
+ * @deprecated This component is deprecated and will be removed in future releases.
41
+ * Please find out the new `ListItem` component props from the `@webiny/admin-ui` package instead.
42
+ */
43
+ export const ListTextOverline = props => {
44
+ const listItemContext = useContext(DeprecatedListItemContext);
45
+ useEffect(() => {
46
+ listItemContext.addDescription(props.children);
47
+ }, [props]);
48
+ return null;
49
+ };
50
+
51
+ //# sourceMappingURL=ListItemText.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["useContext","useEffect","DeprecatedListItemContext","ListItemText","props","listItemContext","onClick","addOnClickCallback","children","ListItemTextPrimary","addTitle","ListItemTextSecondary","addDescription","ListTextOverline"],"sources":["ListItemText.tsx"],"sourcesContent":["import React, { useContext, useEffect } from \"react\";\nimport { DeprecatedListItemContext } from \"~/List\";\n\n/** Text Wrapper for the ListItem */\nexport type ListItemTextProps = {\n children: React.ReactNode;\n className?: string;\n onClick?: (e: React.MouseEvent<HTMLDivElement, MouseEvent>) => void;\n};\n\n/**\n * @deprecated This component is deprecated and will be removed in future releases.\n * Please find out the new `ListItem` component props from the `@webiny/admin-ui` package instead.\n */\nexport const ListItemText = (props: ListItemTextProps) => {\n const listItemContext = useContext(DeprecatedListItemContext);\n\n useEffect(() => {\n props.onClick && listItemContext!.addOnClickCallback(props.onClick);\n }, [props]);\n\n return props.children;\n};\n\nexport type ListItemTextPrimaryProps = {\n /**\n * Text content\n */\n children: React.ReactNode;\n};\n\n/**\n * @deprecated This component is deprecated and will be removed in future releases.\n * Please find out the new `ListItem` component props from the `@webiny/admin-ui` package instead.\n */\nexport const ListItemTextPrimary = (props: ListItemTextPrimaryProps) => {\n const listItemContext = useContext(DeprecatedListItemContext);\n\n useEffect(() => {\n listItemContext!.addTitle(props.children);\n }, [props]);\n\n return null;\n};\n\nexport type ListItemTextSecondaryProps = {\n /**\n * Text content\n */\n children: React.ReactNode;\n};\n\n/**\n * @deprecated This component is deprecated and will be removed in future releases.\n * Please find out the new `ListItem` component props from the `@webiny/admin-ui` package instead.\n */\nexport const ListItemTextSecondary = (props: ListItemTextSecondaryProps) => {\n const listItemContext = useContext(DeprecatedListItemContext);\n\n useEffect(() => {\n listItemContext!.addDescription(props.children);\n }, [props]);\n\n return null;\n};\n\nexport type ListTextOverlineProps = {\n children: React.ReactNode;\n};\n\n/**\n * @deprecated This component is deprecated and will be removed in future releases.\n * Please find out the new `ListItem` component props from the `@webiny/admin-ui` package instead.\n */\nexport const ListTextOverline = (props: ListTextOverlineProps) => {\n const listItemContext = useContext(DeprecatedListItemContext);\n\n useEffect(() => {\n listItemContext!.addDescription(props.children);\n }, [props]);\n\n return null;\n};\n"],"mappings":"AAAA,SAAgBA,UAAU,EAAEC,SAAS,QAAQ,OAAO;AACpD,SAASC,yBAAyB;;AAElC;;AAOA;AACA;AACA;AACA;AACA,OAAO,MAAMC,YAAY,GAAIC,KAAwB,IAAK;EACtD,MAAMC,eAAe,GAAGL,UAAU,CAACE,yBAAyB,CAAC;EAE7DD,SAAS,CAAC,MAAM;IACZG,KAAK,CAACE,OAAO,IAAID,eAAe,CAAEE,kBAAkB,CAACH,KAAK,CAACE,OAAO,CAAC;EACvE,CAAC,EAAE,CAACF,KAAK,CAAC,CAAC;EAEX,OAAOA,KAAK,CAACI,QAAQ;AACzB,CAAC;AASD;AACA;AACA;AACA;AACA,OAAO,MAAMC,mBAAmB,GAAIL,KAA+B,IAAK;EACpE,MAAMC,eAAe,GAAGL,UAAU,CAACE,yBAAyB,CAAC;EAE7DD,SAAS,CAAC,MAAM;IACZI,eAAe,CAAEK,QAAQ,CAACN,KAAK,CAACI,QAAQ,CAAC;EAC7C,CAAC,EAAE,CAACJ,KAAK,CAAC,CAAC;EAEX,OAAO,IAAI;AACf,CAAC;AASD;AACA;AACA;AACA;AACA,OAAO,MAAMO,qBAAqB,GAAIP,KAAiC,IAAK;EACxE,MAAMC,eAAe,GAAGL,UAAU,CAACE,yBAAyB,CAAC;EAE7DD,SAAS,CAAC,MAAM;IACZI,eAAe,CAAEO,cAAc,CAACR,KAAK,CAACI,QAAQ,CAAC;EACnD,CAAC,EAAE,CAACJ,KAAK,CAAC,CAAC;EAEX,OAAO,IAAI;AACf,CAAC;AAMD;AACA;AACA;AACA;AACA,OAAO,MAAMS,gBAAgB,GAAIT,KAA4B,IAAK;EAC9D,MAAMC,eAAe,GAAGL,UAAU,CAACE,yBAAyB,CAAC;EAE7DD,SAAS,CAAC,MAAM;IACZI,eAAe,CAAEO,cAAc,CAACR,KAAK,CAACI,QAAQ,CAAC;EACnD,CAAC,EAAE,CAACJ,KAAK,CAAC,CAAC;EAEX,OAAO,IAAI;AACf,CAAC","ignoreList":[]}
@@ -0,0 +1,6 @@
1
+ export * from "./List";
2
+ export * from "./ListItem";
3
+ export * from "./ListItemAction";
4
+ export * from "./ListItemGraphic";
5
+ export * from "./ListItemMeta";
6
+ export * from "./ListItemText";
@@ -0,0 +1,8 @@
1
+ export * from "./List";
2
+ export * from "./ListItem";
3
+ export * from "./ListItemAction";
4
+ export * from "./ListItemGraphic";
5
+ export * from "./ListItemMeta";
6
+ export * from "./ListItemText";
7
+
8
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":[],"sources":["index.ts"],"sourcesContent":["export * from \"./List\";\nexport * from \"./ListItem\";\nexport * from \"./ListItemAction\";\nexport * from \"./ListItemGraphic\";\nexport * from \"./ListItemMeta\";\nexport * from \"./ListItemText\";\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA","ignoreList":[]}
package/List/index.d.ts CHANGED
@@ -1,3 +1,4 @@
1
1
  export * from "./List";
2
2
  export { DataList, ScrollList, DataListModalOverlay, DataListModalOverlayAction, DataListWithSections, ScrollListWithSections } from "./DataList";
3
+ export * from "./DataList/icons";
3
4
  export { CollapsibleList } from "./CollapsibleList";
package/List/index.js CHANGED
@@ -1,72 +1,6 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- var _exportNames = {
7
- DataList: true,
8
- ScrollList: true,
9
- DataListModalOverlay: true,
10
- DataListModalOverlayAction: true,
11
- DataListWithSections: true,
12
- ScrollListWithSections: true,
13
- CollapsibleList: true
14
- };
15
- Object.defineProperty(exports, "CollapsibleList", {
16
- enumerable: true,
17
- get: function get() {
18
- return _CollapsibleList.CollapsibleList;
19
- }
20
- });
21
- Object.defineProperty(exports, "DataList", {
22
- enumerable: true,
23
- get: function get() {
24
- return _DataList.DataList;
25
- }
26
- });
27
- Object.defineProperty(exports, "DataListModalOverlay", {
28
- enumerable: true,
29
- get: function get() {
30
- return _DataList.DataListModalOverlay;
31
- }
32
- });
33
- Object.defineProperty(exports, "DataListModalOverlayAction", {
34
- enumerable: true,
35
- get: function get() {
36
- return _DataList.DataListModalOverlayAction;
37
- }
38
- });
39
- Object.defineProperty(exports, "DataListWithSections", {
40
- enumerable: true,
41
- get: function get() {
42
- return _DataList.DataListWithSections;
43
- }
44
- });
45
- Object.defineProperty(exports, "ScrollList", {
46
- enumerable: true,
47
- get: function get() {
48
- return _DataList.ScrollList;
49
- }
50
- });
51
- Object.defineProperty(exports, "ScrollListWithSections", {
52
- enumerable: true,
53
- get: function get() {
54
- return _DataList.ScrollListWithSections;
55
- }
56
- });
57
- var _List = require("./List");
58
- Object.keys(_List).forEach(function (key) {
59
- if (key === "default" || key === "__esModule") return;
60
- if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
61
- if (key in exports && exports[key] === _List[key]) return;
62
- Object.defineProperty(exports, key, {
63
- enumerable: true,
64
- get: function get() {
65
- return _List[key];
66
- }
67
- });
68
- });
69
- var _DataList = require("./DataList");
70
- var _CollapsibleList = require("./CollapsibleList");
1
+ export * from "./List";
2
+ export { DataList, ScrollList, DataListModalOverlay, DataListModalOverlayAction, DataListWithSections, ScrollListWithSections } from "./DataList";
3
+ export * from "./DataList/icons";
4
+ export { CollapsibleList } from "./CollapsibleList";
71
5
 
72
6
  //# sourceMappingURL=index.js.map
package/List/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"names":["_List","require","Object","keys","forEach","key","prototype","hasOwnProperty","call","_exportNames","exports","defineProperty","enumerable","get","_DataList","_CollapsibleList"],"sources":["index.ts"],"sourcesContent":["export * from \"./List\";\n\nexport {\n DataList,\n ScrollList,\n DataListModalOverlay,\n DataListModalOverlayAction,\n DataListWithSections,\n ScrollListWithSections\n} from \"./DataList\";\nexport { CollapsibleList } from \"./CollapsibleList\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,KAAA,GAAAC,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAH,KAAA,EAAAI,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAH,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAC,YAAA,EAAAJ,GAAA;EAAA,IAAAA,GAAA,IAAAK,OAAA,IAAAA,OAAA,CAAAL,GAAA,MAAAL,KAAA,CAAAK,GAAA;EAAAH,MAAA,CAAAS,cAAA,CAAAD,OAAA,EAAAL,GAAA;IAAAO,UAAA;IAAAC,GAAA,WAAAA,IAAA;MAAA,OAAAb,KAAA,CAAAK,GAAA;IAAA;EAAA;AAAA;AAEA,IAAAS,SAAA,GAAAb,OAAA;AAQA,IAAAc,gBAAA,GAAAd,OAAA","ignoreList":[]}
1
+ {"version":3,"names":["DataList","ScrollList","DataListModalOverlay","DataListModalOverlayAction","DataListWithSections","ScrollListWithSections","CollapsibleList"],"sources":["index.ts"],"sourcesContent":["export * from \"./List\";\n\nexport {\n DataList,\n ScrollList,\n DataListModalOverlay,\n DataListModalOverlayAction,\n DataListWithSections,\n ScrollListWithSections\n} from \"./DataList\";\nexport * from \"./DataList/icons\";\nexport { CollapsibleList } from \"./CollapsibleList\";\n"],"mappings":"AAAA;AAEA,SACIA,QAAQ,EACRC,UAAU,EACVC,oBAAoB,EACpBC,0BAA0B,EAC1BC,oBAAoB,EACpBC,sBAAsB;AAE1B;AACA,SAASC,eAAe","ignoreList":[]}
package/Menu/Menu.d.ts CHANGED
@@ -1,12 +1,39 @@
1
1
  import React from "react";
2
- import { MenuProps as RmwcMenuProps, MenuItemProps as BaseMenuItemProps } from "@rmwc/menu";
3
2
  export type MenuChildrenFunctionProps = {
4
3
  closeMenu: () => void;
5
4
  };
6
5
  export interface RenderableMenuChildren {
7
6
  (props: MenuChildrenFunctionProps): React.ReactNode;
8
7
  }
9
- export type MenuProps = Omit<RmwcMenuProps, "children"> & {
8
+ export interface BaseMenuItemProps {
9
+ /** Adds a ripple effect to the component */
10
+ ripple?: any;
11
+ /** A modifier for a selected state. */
12
+ selected?: boolean;
13
+ /** A modifier for an active state. */
14
+ activated?: boolean;
15
+ /** A modifier for a disabled state. */
16
+ disabled?: boolean;
17
+ }
18
+ export type MenuProps = {
19
+ /** Opens the menu. */
20
+ open?: boolean;
21
+ /** Make the menu position fixed. */
22
+ fixed?: boolean;
23
+ /** Renders the menu to a portal. Useful for situations where the content might be cutoff by an overflow: hidden container. You can pass "true" to render to the default RMWC portal. */
24
+ renderToPortal?: any;
25
+ /** Manually position the menu to one of the corners. */
26
+ anchorCorner?: any;
27
+ /** Children to render. */
28
+ children?: React.ReactNode;
29
+ /** An internal api for cross component communication. */
30
+ apiRef?: (api: any | null) => void;
31
+ /** Advanced: A reference to the MDCFoundation. */
32
+ foundationRef?: any;
33
+ /** Callback that fires when a Menu item is selected. evt.detail = { index: number; item: HTMLElement; } */
34
+ onSelect?: (evt: any) => void;
35
+ /** Whether or not to focus the first list item on open. Defaults to true. */
36
+ focusOnOpen?: boolean;
10
37
  handle?: React.ReactElement;
11
38
  anchor?: "bottomEnd" | "bottomLeft" | "bottomRight" | "bottomStart" | "topEnd" | "topLeft" | "topRight" | "topStart";
12
39
  className?: string;
@@ -23,9 +50,14 @@ export type MenuProps = Omit<RmwcMenuProps, "children"> & {
23
50
  children?: never;
24
51
  });
25
52
  /**
26
- * Use Menu component to display a list of choices, once the handler is triggered.
53
+ * @deprecated This component is deprecated and will be removed in future releases.
54
+ * Please use the `DropdownMenu` component from the `@webiny/admin-ui` package instead.
27
55
  */
28
56
  declare const Menu: (props: MenuProps) => React.JSX.Element;
57
+ /**
58
+ * @deprecated This component is deprecated and will be removed in future releases.
59
+ * Please use the `DropdownMenu.Separator` component from the `@webiny/admin-ui` package instead.
60
+ */
29
61
  declare const MenuDivider: () => React.JSX.Element;
30
62
  interface MenuItemProps extends BaseMenuItemProps {
31
63
  children: React.ReactNode;
@@ -33,5 +65,9 @@ interface MenuItemProps extends BaseMenuItemProps {
33
65
  onClick?: (event: React.MouseEvent) => void;
34
66
  "data-testid"?: string;
35
67
  }
36
- declare const MenuItem: ({ disabled, className, ...rest }: MenuItemProps) => React.JSX.Element;
68
+ /**
69
+ * @deprecated This component is deprecated and will be removed in future releases.
70
+ * Please use the `DropdownMenu/Item` component from the `@webiny/admin-ui` package instead.
71
+ */
72
+ declare const MenuItem: ({ children, ...rest }: MenuItemProps) => React.JSX.Element;
37
73
  export { Menu, MenuItem, MenuDivider };
package/Menu/Menu.js CHANGED
@@ -1,109 +1,83 @@
1
- "use strict";
1
+ import React, { useMemo } from "react";
2
+ import { DropdownMenu as AdminUiDropdownMenu } from "@webiny/admin-ui/DropdownMenu";
3
+ import { ListItemGraphic } from "../List";
4
+ /**
5
+ * @deprecated This component is deprecated and will be removed in future releases.
6
+ * Please use the `DropdownMenu` component from the `@webiny/admin-ui` package instead.
7
+ */
8
+ const Menu = props => {
9
+ const {
10
+ children,
11
+ handle,
12
+ className,
13
+ onOpen,
14
+ open,
15
+ onClose
2
16
 
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
- var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
5
- Object.defineProperty(exports, "__esModule", {
6
- value: true
7
- });
8
- exports.MenuItem = exports.MenuDivider = exports.Menu = void 0;
9
- var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
10
- var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
11
- var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
12
- var _react = _interopRequireWildcard(require("react"));
13
- var _menu = require("@rmwc/menu");
14
- var _emotion = require("emotion");
15
- var _classnames = _interopRequireDefault(require("classnames"));
16
- var _excluded = ["disabled", "className"];
17
- var style = {
18
- disabledMenuItem: (0, _emotion.css)({
19
- opacity: 0.5,
20
- pointerEvents: "none"
21
- })
17
+ // Deprecated properties.
18
+ // disabled,
19
+ // onSelect,
20
+ // anchor = "topStart",
21
+ // render,
22
+ // renderToPortal,
23
+ // portalZIndex = 99
24
+ } = props;
25
+ return /*#__PURE__*/React.createElement(AdminUiDropdownMenu, {
26
+ open: open,
27
+ trigger: handle,
28
+ className: className,
29
+ onOpenChange: open => {
30
+ if (open) {
31
+ onOpen && onOpen();
32
+ } else {
33
+ onClose && onClose();
34
+ }
35
+ },
36
+ "data-testid": props["data-testid"]
37
+ }, typeof children === "function" ? children({
38
+ closeMenu: () => {
39
+ console.log("Deprecated: This function is deprecated and will be removed in future releases.");
40
+ }
41
+ }) : children);
22
42
  };
43
+
23
44
  /**
24
- * Use Menu component to display a list of choices, once the handler is triggered.
45
+ * @deprecated This component is deprecated and will be removed in future releases.
46
+ * Please use the `DropdownMenu.Separator` component from the `@webiny/admin-ui` package instead.
25
47
  */
26
- var Menu = exports.Menu = function Menu(props) {
27
- var children = props.children,
28
- handle = props.handle,
29
- _props$anchor = props.anchor,
30
- anchor = _props$anchor === void 0 ? "topStart" : _props$anchor,
31
- className = props.className,
32
- disabled = props.disabled,
33
- onOpen = props.onOpen,
34
- onClose = props.onClose,
35
- onSelect = props.onSelect,
36
- open = props.open,
37
- render = props.render,
38
- renderToPortal = props.renderToPortal,
39
- _props$portalZIndex = props.portalZIndex,
40
- portalZIndex = _props$portalZIndex === void 0 ? 99 : _props$portalZIndex;
41
- var _useState = (0, _react.useState)(false),
42
- _useState2 = (0, _slicedToArray2.default)(_useState, 2),
43
- menuIsOpen = _useState2[0],
44
- setMenuIsOpen = _useState2[1];
45
- (0, _react.useEffect)(function () {
46
- if (typeof open === "boolean") {
47
- setMenuIsOpen(open);
48
- }
49
- }, [open]);
50
- var openMenu = (0, _react.useCallback)(function () {
51
- if (disabled) {
52
- return;
53
- }
54
- setMenuIsOpen(true);
55
- if (onOpen) {
56
- onOpen();
57
- }
58
- }, [disabled, onOpen]);
59
- var closeMenu = (0, _react.useCallback)(function () {
60
- setMenuIsOpen(false);
61
- if (onClose) {
62
- onClose();
63
- }
64
- }, [onClose]);
65
- var renderMenuWithPortal = function renderMenuWithPortal() {
66
- return /*#__PURE__*/_react.default.createElement(_menu.Menu, {
67
- anchorCorner: anchor,
68
- open: menuIsOpen,
69
- className: className,
70
- onClose: closeMenu,
71
- onSelect: onSelect,
72
- renderToPortal: true,
73
- style: {
74
- zIndex: portalZIndex
75
- } // Fixes Menu in Drawers
76
- }, /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, children));
77
- };
78
- var renderCustomContent = function renderCustomContent() {
79
- var renderer = render || children;
80
- return /*#__PURE__*/_react.default.createElement(_menu.MenuSurface, {
81
- open: menuIsOpen,
82
- onClose: closeMenu,
83
- renderToPortal: renderToPortal
84
- }, typeof renderer === "function" ? renderer({
85
- closeMenu: closeMenu
86
- }) : renderer);
87
- };
88
- return /*#__PURE__*/_react.default.createElement(_menu.MenuSurfaceAnchor, {
89
- "data-testid": props["data-testid"]
90
- }, Array.isArray(children) ? renderMenuWithPortal() : renderCustomContent(), handle && /*#__PURE__*/_react.default.cloneElement(handle, {
91
- onClick: openMenu
92
- }));
48
+ const MenuDivider = () => {
49
+ return /*#__PURE__*/React.createElement(AdminUiDropdownMenu.Separator, null);
93
50
  };
94
- var MenuDivider = exports.MenuDivider = function MenuDivider() {
95
- return /*#__PURE__*/_react.default.createElement("li", {
96
- className: "mdc-list-divider",
97
- role: "separator"
98
- });
51
+ const isIconElement = element => {
52
+ return /*#__PURE__*/React.isValidElement(element) && element.type === ListItemGraphic;
99
53
  };
100
- var MenuItem = exports.MenuItem = function MenuItem(_ref) {
101
- var disabled = _ref.disabled,
102
- className = _ref.className,
103
- rest = (0, _objectWithoutProperties2.default)(_ref, _excluded);
104
- return /*#__PURE__*/_react.default.createElement(_menu.MenuItem, Object.assign({}, rest, {
105
- className: (0, _classnames.default)(className, (0, _defineProperty2.default)({}, style.disabledMenuItem, disabled))
106
- }));
54
+
55
+ /**
56
+ * @deprecated This component is deprecated and will be removed in future releases.
57
+ * Please use the `DropdownMenu/Item` component from the `@webiny/admin-ui` package instead.
58
+ */
59
+ const MenuItem = ({
60
+ children,
61
+ ...rest
62
+ }) => {
63
+ const icon = useMemo(() => {
64
+ const foundIcon = React.Children.toArray(children).find(isIconElement);
65
+ // Handles this usage: packages/app-admin/src/components/OptionsMenu/OptionsMenuItem.tsx
66
+ if (/*#__PURE__*/React.isValidElement(foundIcon) && foundIcon.type === ListItemGraphic) {
67
+ return foundIcon.props.children;
68
+ }
69
+ return foundIcon;
70
+ }, [children]);
71
+ const content = useMemo(() => {
72
+ return React.Children.toArray(children).filter(child => {
73
+ return !isIconElement(child);
74
+ });
75
+ }, [children]);
76
+ return /*#__PURE__*/React.createElement(AdminUiDropdownMenu.Item, Object.assign({
77
+ icon: icon,
78
+ text: content
79
+ }, rest));
107
80
  };
81
+ export { Menu, MenuItem, MenuDivider };
108
82
 
109
83
  //# sourceMappingURL=Menu.js.map
package/Menu/Menu.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"names":["_react","_interopRequireWildcard","require","_menu","_emotion","_classnames","_interopRequireDefault","_excluded","style","disabledMenuItem","css","opacity","pointerEvents","Menu","exports","props","children","handle","_props$anchor","anchor","className","disabled","onOpen","onClose","onSelect","open","render","renderToPortal","_props$portalZIndex","portalZIndex","_useState","useState","_useState2","_slicedToArray2","default","menuIsOpen","setMenuIsOpen","useEffect","openMenu","useCallback","closeMenu","renderMenuWithPortal","createElement","anchorCorner","zIndex","Fragment","renderCustomContent","renderer","MenuSurface","MenuSurfaceAnchor","Array","isArray","React","cloneElement","onClick","MenuDivider","role","MenuItem","_ref","rest","_objectWithoutProperties2","Object","assign","classNames","_defineProperty2"],"sources":["Menu.tsx"],"sourcesContent":["import React, { useState, useEffect, useCallback } from \"react\";\nimport {\n Menu as BaseMenu,\n MenuProps as RmwcMenuProps,\n MenuItem as BaseMenuItem,\n MenuItemProps as BaseMenuItemProps,\n MenuSurface,\n MenuSurfaceAnchor\n} from \"@rmwc/menu\";\nimport { css } from \"emotion\";\nimport classNames from \"classnames\";\n\nconst style = {\n disabledMenuItem: css({\n opacity: 0.5,\n pointerEvents: \"none\"\n })\n};\n\nexport type MenuChildrenFunctionProps = {\n closeMenu: () => void;\n};\n\nexport interface RenderableMenuChildren {\n (props: MenuChildrenFunctionProps): React.ReactNode;\n}\n\nexport type MenuProps = Omit<RmwcMenuProps, \"children\"> & {\n // A handler which triggers the menu, e.g. button or link.\n handle?: React.ReactElement;\n\n // Position the menu to one of anchor corners.\n // 'bottomEnd' | 'bottomLeft' | 'bottomRight' | 'bottomStart' | 'topEnd' | 'topLeft' | 'topRight' | 'topStart'\n anchor?:\n | \"bottomEnd\"\n | \"bottomLeft\"\n | \"bottomRight\"\n | \"bottomStart\"\n | \"topEnd\"\n | \"topLeft\"\n | \"topRight\"\n | \"topStart\";\n\n // Class that will be added to the Menu element.\n className?: string;\n\n // If true, prevents menu from opening when clicked.\n disabled?: boolean;\n\n onOpen?: () => void;\n onClose?: () => void;\n\n // For testing purposes.\n \"data-testid\"?: string;\n\n // If rendering to portal, you can specify an exact zIndex.\n portalZIndex?: number;\n} & ( // You can use either `children` or `render`, but not both.\n | {\n // One or more MenuItem components.\n children: React.ReactNode | RenderableMenuChildren;\n render?: never;\n }\n | {\n render: RenderableMenuChildren;\n children?: never;\n }\n );\n\n/**\n * Use Menu component to display a list of choices, once the handler is triggered.\n */\nconst Menu = (props: MenuProps) => {\n const {\n children,\n handle,\n anchor = \"topStart\",\n className,\n disabled,\n onOpen,\n onClose,\n onSelect,\n open,\n render,\n renderToPortal,\n portalZIndex = 99\n } = props;\n\n const [menuIsOpen, setMenuIsOpen] = useState(false);\n\n useEffect(() => {\n if (typeof open === \"boolean\") {\n setMenuIsOpen(open);\n }\n }, [open]);\n\n const openMenu = useCallback(() => {\n if (disabled) {\n return;\n }\n\n setMenuIsOpen(true);\n\n if (onOpen) {\n onOpen();\n }\n }, [disabled, onOpen]);\n\n const closeMenu = useCallback(() => {\n setMenuIsOpen(false);\n\n if (onClose) {\n onClose();\n }\n }, [onClose]);\n\n const renderMenuWithPortal = () => (\n <BaseMenu\n anchorCorner={anchor}\n open={menuIsOpen}\n className={className}\n onClose={closeMenu}\n onSelect={onSelect}\n renderToPortal={true}\n style={{ zIndex: portalZIndex }} // Fixes Menu in Drawers\n >\n <>{children}</>\n </BaseMenu>\n );\n\n const renderCustomContent = () => {\n const renderer = render || children;\n return (\n <MenuSurface open={menuIsOpen} onClose={closeMenu} renderToPortal={renderToPortal}>\n {typeof renderer === \"function\" ? renderer({ closeMenu }) : renderer}\n </MenuSurface>\n );\n };\n\n return (\n <MenuSurfaceAnchor data-testid={props[\"data-testid\"]}>\n {Array.isArray(children) ? renderMenuWithPortal() : renderCustomContent()}\n {handle && React.cloneElement(handle, { onClick: openMenu })}\n </MenuSurfaceAnchor>\n );\n};\n\nconst MenuDivider = () => {\n return <li className=\"mdc-list-divider\" role=\"separator\" />;\n};\n\ninterface MenuItemProps extends BaseMenuItemProps {\n children: React.ReactNode;\n className?: string;\n onClick?: (event: React.MouseEvent) => void;\n \"data-testid\"?: string;\n}\n\nconst MenuItem = ({ disabled, className, ...rest }: MenuItemProps) => {\n return (\n <BaseMenuItem\n {...rest}\n className={classNames(className, { [style.disabledMenuItem]: disabled })}\n />\n );\n};\n\nexport { Menu, MenuItem, MenuDivider };\n"],"mappings":"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","ignoreList":[]}
1
+ {"version":3,"names":["React","useMemo","DropdownMenu","AdminUiDropdownMenu","ListItemGraphic","Menu","props","children","handle","className","onOpen","open","onClose","createElement","trigger","onOpenChange","closeMenu","console","log","MenuDivider","Separator","isIconElement","element","isValidElement","type","MenuItem","rest","icon","foundIcon","Children","toArray","find","content","filter","child","Item","Object","assign","text"],"sources":["Menu.tsx"],"sourcesContent":["import React, { useMemo } from \"react\";\nimport { DropdownMenu as AdminUiDropdownMenu } from \"@webiny/admin-ui/DropdownMenu\";\nimport { ListItemGraphic } from \"~/List\";\n\nexport type MenuChildrenFunctionProps = {\n closeMenu: () => void;\n};\n\nexport interface RenderableMenuChildren {\n (props: MenuChildrenFunctionProps): React.ReactNode;\n}\n\nexport interface BaseMenuItemProps {\n /** Adds a ripple effect to the component */\n ripple?: any;\n /** A modifier for a selected state. */\n selected?: boolean;\n /** A modifier for an active state. */\n activated?: boolean;\n /** A modifier for a disabled state. */\n disabled?: boolean;\n}\n\nexport type MenuProps = {\n /** Opens the menu. */\n open?: boolean;\n /** Make the menu position fixed. */\n fixed?: boolean;\n /** Renders the menu to a portal. Useful for situations where the content might be cutoff by an overflow: hidden container. You can pass \"true\" to render to the default RMWC portal. */\n renderToPortal?: any;\n /** Manually position the menu to one of the corners. */\n anchorCorner?: any;\n /** Children to render. */\n children?: React.ReactNode;\n /** An internal api for cross component communication. */\n apiRef?: (api: any | null) => void;\n /** Advanced: A reference to the MDCFoundation. */\n foundationRef?: any;\n /** Callback that fires when a Menu item is selected. evt.detail = { index: number; item: HTMLElement; } */\n onSelect?: (evt: any) => void;\n /** Whether or not to focus the first list item on open. Defaults to true. */\n focusOnOpen?: boolean;\n\n // A handler which triggers the menu, e.g. button or link.\n handle?: React.ReactElement;\n\n // @deprecated With the introduction of the new Admin UI, this prop is no longer supported, and it will be removed in future releases.\n // Position the menu to one of anchor corners.\n // 'bottomEnd' | 'bottomLeft' | 'bottomRight' | 'bottomStart' | 'topEnd' | 'topLeft' | 'topRight' | 'topStart'\n anchor?:\n | \"bottomEnd\"\n | \"bottomLeft\"\n | \"bottomRight\"\n | \"bottomStart\"\n | \"topEnd\"\n | \"topLeft\"\n | \"topRight\"\n | \"topStart\";\n\n // Class that will be added to the Menu element.\n className?: string;\n\n // @deprecated With the introduction of the new Admin UI, this prop is no longer supported, and it will be removed in future releases.\n // If true, prevents menu from opening when clicked.\n disabled?: boolean;\n\n onOpen?: () => void;\n onClose?: () => void;\n\n // For testing purposes.\n \"data-testid\"?: string;\n\n // @deprecated With the introduction of the new Admin UI, this prop is no longer supported, and it will be removed in future releases.\n // If rendering to portal, you can specify an exact zIndex.\n portalZIndex?: number;\n} & ( // You can use either `children` or `render`, but not both.\n | {\n // One or more MenuItem components.\n children: React.ReactNode | RenderableMenuChildren;\n render?: never;\n }\n | {\n render: RenderableMenuChildren;\n children?: never;\n }\n);\n\n/**\n * @deprecated This component is deprecated and will be removed in future releases.\n * Please use the `DropdownMenu` component from the `@webiny/admin-ui` package instead.\n */\nconst Menu = (props: MenuProps) => {\n const {\n children,\n handle,\n\n className,\n onOpen,\n open,\n onClose\n\n // Deprecated properties.\n // disabled,\n // onSelect,\n // anchor = \"topStart\",\n // render,\n // renderToPortal,\n // portalZIndex = 99\n } = props;\n\n return (\n <AdminUiDropdownMenu\n open={open}\n trigger={handle}\n className={className}\n onOpenChange={open => {\n if (open) {\n onOpen && onOpen();\n } else {\n onClose && onClose();\n }\n }}\n data-testid={props[\"data-testid\"]}\n >\n {typeof children === \"function\"\n ? children({\n closeMenu: () => {\n console.log(\n \"Deprecated: This function is deprecated and will be removed in future releases.\"\n );\n }\n })\n : children}\n </AdminUiDropdownMenu>\n );\n};\n\n/**\n * @deprecated This component is deprecated and will be removed in future releases.\n * Please use the `DropdownMenu.Separator` component from the `@webiny/admin-ui` package instead.\n */\nconst MenuDivider = () => {\n return <AdminUiDropdownMenu.Separator />;\n};\n\ninterface MenuItemProps extends BaseMenuItemProps {\n children: React.ReactNode;\n className?: string;\n onClick?: (event: React.MouseEvent) => void;\n \"data-testid\"?: string;\n}\n\nconst isIconElement = (element: React.ReactNode) => {\n return React.isValidElement(element) && element.type === ListItemGraphic;\n};\n\n/**\n * @deprecated This component is deprecated and will be removed in future releases.\n * Please use the `DropdownMenu/Item` component from the `@webiny/admin-ui` package instead.\n */\nconst MenuItem = ({ children, ...rest }: MenuItemProps) => {\n const icon = useMemo(() => {\n const foundIcon = React.Children.toArray(children).find(isIconElement);\n // Handles this usage: packages/app-admin/src/components/OptionsMenu/OptionsMenuItem.tsx\n if (React.isValidElement(foundIcon) && foundIcon.type === ListItemGraphic) {\n return foundIcon.props.children;\n }\n return foundIcon;\n }, [children]);\n\n const content = useMemo(() => {\n return React.Children.toArray(children).filter(child => {\n return !isIconElement(child);\n });\n }, [children]);\n\n return <AdminUiDropdownMenu.Item icon={icon} text={content} {...rest} />;\n};\n\nexport { Menu, MenuItem, MenuDivider };\n"],"mappings":"AAAA,OAAOA,KAAK,IAAIC,OAAO,QAAQ,OAAO;AACtC,SAASC,YAAY,IAAIC,mBAAmB,QAAQ,+BAA+B;AACnF,SAASC,eAAe;AAqFxB;AACA;AACA;AACA;AACA,MAAMC,IAAI,GAAIC,KAAgB,IAAK;EAC/B,MAAM;IACFC,QAAQ;IACRC,MAAM;IAENC,SAAS;IACTC,MAAM;IACNC,IAAI;IACJC;;IAEA;IACA;IACA;IACA;IACA;IACA;IACA;EACJ,CAAC,GAAGN,KAAK;EAET,oBACIN,KAAA,CAAAa,aAAA,CAACV,mBAAmB;IAChBQ,IAAI,EAAEA,IAAK;IACXG,OAAO,EAAEN,MAAO;IAChBC,SAAS,EAAEA,SAAU;IACrBM,YAAY,EAAEJ,IAAI,IAAI;MAClB,IAAIA,IAAI,EAAE;QACND,MAAM,IAAIA,MAAM,CAAC,CAAC;MACtB,CAAC,MAAM;QACHE,OAAO,IAAIA,OAAO,CAAC,CAAC;MACxB;IACJ,CAAE;IACF,eAAaN,KAAK,CAAC,aAAa;EAAE,GAEjC,OAAOC,QAAQ,KAAK,UAAU,GACzBA,QAAQ,CAAC;IACLS,SAAS,EAAEA,CAAA,KAAM;MACbC,OAAO,CAACC,GAAG,CACP,iFACJ,CAAC;IACL;EACJ,CAAC,CAAC,GACFX,QACW,CAAC;AAE9B,CAAC;;AAED;AACA;AACA;AACA;AACA,MAAMY,WAAW,GAAGA,CAAA,KAAM;EACtB,oBAAOnB,KAAA,CAAAa,aAAA,CAACV,mBAAmB,CAACiB,SAAS,MAAE,CAAC;AAC5C,CAAC;AASD,MAAMC,aAAa,GAAIC,OAAwB,IAAK;EAChD,OAAO,aAAAtB,KAAK,CAACuB,cAAc,CAACD,OAAO,CAAC,IAAIA,OAAO,CAACE,IAAI,KAAKpB,eAAe;AAC5E,CAAC;;AAED;AACA;AACA;AACA;AACA,MAAMqB,QAAQ,GAAGA,CAAC;EAAElB,QAAQ;EAAE,GAAGmB;AAAoB,CAAC,KAAK;EACvD,MAAMC,IAAI,GAAG1B,OAAO,CAAC,MAAM;IACvB,MAAM2B,SAAS,GAAG5B,KAAK,CAAC6B,QAAQ,CAACC,OAAO,CAACvB,QAAQ,CAAC,CAACwB,IAAI,CAACV,aAAa,CAAC;IACtE;IACA,IAAI,aAAArB,KAAK,CAACuB,cAAc,CAACK,SAAS,CAAC,IAAIA,SAAS,CAACJ,IAAI,KAAKpB,eAAe,EAAE;MACvE,OAAOwB,SAAS,CAACtB,KAAK,CAACC,QAAQ;IACnC;IACA,OAAOqB,SAAS;EACpB,CAAC,EAAE,CAACrB,QAAQ,CAAC,CAAC;EAEd,MAAMyB,OAAO,GAAG/B,OAAO,CAAC,MAAM;IAC1B,OAAOD,KAAK,CAAC6B,QAAQ,CAACC,OAAO,CAACvB,QAAQ,CAAC,CAAC0B,MAAM,CAACC,KAAK,IAAI;MACpD,OAAO,CAACb,aAAa,CAACa,KAAK,CAAC;IAChC,CAAC,CAAC;EACN,CAAC,EAAE,CAAC3B,QAAQ,CAAC,CAAC;EAEd,oBAAOP,KAAA,CAAAa,aAAA,CAACV,mBAAmB,CAACgC,IAAI,EAAAC,MAAA,CAAAC,MAAA;IAACV,IAAI,EAAEA,IAAK;IAACW,IAAI,EAAEN;EAAQ,GAAKN,IAAI,CAAG,CAAC;AAC5E,CAAC;AAED,SAASrB,IAAI,EAAEoB,QAAQ,EAAEN,WAAW","ignoreList":[]}
package/Menu/index.js CHANGED
@@ -1,18 +1,3 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- var _Menu = require("./Menu");
7
- Object.keys(_Menu).forEach(function (key) {
8
- if (key === "default" || key === "__esModule") return;
9
- if (key in exports && exports[key] === _Menu[key]) return;
10
- Object.defineProperty(exports, key, {
11
- enumerable: true,
12
- get: function get() {
13
- return _Menu[key];
14
- }
15
- });
16
- });
1
+ export * from "./Menu";
17
2
 
18
3
  //# sourceMappingURL=index.js.map
package/Menu/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"names":["_Menu","require","Object","keys","forEach","key","exports","defineProperty","enumerable","get"],"sources":["index.ts"],"sourcesContent":["export * from \"./Menu\";\n"],"mappings":";;;;;AAAA,IAAAA,KAAA,GAAAC,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAH,KAAA,EAAAI,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAL,KAAA,CAAAK,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,IAAA;MAAA,OAAAT,KAAA,CAAAK,GAAA;IAAA;EAAA;AAAA","ignoreList":[]}
1
+ {"version":3,"names":[],"sources":["index.ts"],"sourcesContent":["export * from \"./Menu\";\n"],"mappings":"AAAA","ignoreList":[]}
@@ -1,10 +1,10 @@
1
1
  import React from "react";
2
- export interface MosaicProps {
3
- columns?: {
4
- [key: string]: number;
5
- };
6
- className?: string;
2
+ export interface MosaicProps extends Record<string, any> {
7
3
  children: React.ReactNode;
8
4
  }
5
+ /**
6
+ * @deprecated This component is deprecated and will be removed in future releases.
7
+ * Please implement your own `Mosaic` component or reach out on Slack.
8
+ */
9
9
  declare const Mosaic: (props: MosaicProps) => React.JSX.Element;
10
10
  export { Mosaic };
package/Mosaic/Mosaic.js CHANGED
@@ -1,31 +1,11 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
- Object.defineProperty(exports, "__esModule", {
5
- value: true
6
- });
7
- exports.Mosaic = void 0;
8
- var _react = _interopRequireDefault(require("react"));
9
- var _reactColumned = _interopRequireDefault(require("react-columned"));
1
+ import React from "react";
10
2
  /**
11
- * Package react-columned does not have types.
3
+ * @deprecated This component is deprecated and will be removed in future releases.
4
+ * Please implement your own `Mosaic` component or reach out on Slack.
12
5
  */
13
- // @ts-expect-error
14
-
15
- var Mosaic = exports.Mosaic = function Mosaic(props) {
16
- var children = props.children,
17
- _props$columns = props.columns,
18
- columns = _props$columns === void 0 ? {
19
- 320: 1,
20
- 480: 2,
21
- 800: 3,
22
- 1366: 4
23
- } : _props$columns,
24
- className = props.className;
25
- return /*#__PURE__*/_react.default.createElement(_reactColumned.default, {
26
- columns: columns,
27
- className: className
28
- }, children);
6
+ const Mosaic = props => {
7
+ return /*#__PURE__*/React.createElement(React.Fragment, null, props.children);
29
8
  };
9
+ export { Mosaic };
30
10
 
31
11
  //# sourceMappingURL=Mosaic.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["_react","_interopRequireDefault","require","_reactColumned","Mosaic","exports","props","children","_props$columns","columns","className","default","createElement"],"sources":["Mosaic.tsx"],"sourcesContent":["import React from \"react\";\n/**\n * Package react-columned does not have types.\n */\n// @ts-expect-error\nimport Columned from \"react-columned\";\n\nexport interface MosaicProps {\n // Number of columns, per max screen size, eg. { \"320\": 1, \"480\": 2, \"800\": 3, \"1366\": 4 }.\n columns?: {\n [key: string]: number;\n };\n\n // Custom class for the mosaic container.\n className?: string;\n\n children: React.ReactNode;\n}\n\nconst Mosaic = (props: MosaicProps) => {\n const { children, columns = { 320: 1, 480: 2, 800: 3, 1366: 4 }, className } = props;\n return (\n <Columned columns={columns} className={className}>\n {children}\n </Columned>\n );\n};\n\nexport { Mosaic };\n"],"mappings":";;;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AAKA,IAAAC,cAAA,GAAAF,sBAAA,CAAAC,OAAA;AAJA;AACA;AACA;AACA;;AAeA,IAAME,MAAM,GAAAC,OAAA,CAAAD,MAAA,GAAG,SAATA,MAAMA,CAAIE,KAAkB,EAAK;EACnC,IAAQC,QAAQ,GAA+DD,KAAK,CAA5EC,QAAQ;IAAAC,cAAA,GAA+DF,KAAK,CAAlEG,OAAO;IAAPA,OAAO,GAAAD,cAAA,cAAG;MAAE,GAAG,EAAE,CAAC;MAAE,GAAG,EAAE,CAAC;MAAE,GAAG,EAAE,CAAC;MAAE,IAAI,EAAE;IAAE,CAAC,GAAAA,cAAA;IAAEE,SAAS,GAAKJ,KAAK,CAAnBI,SAAS;EAC1E,oBACIV,MAAA,CAAAW,OAAA,CAAAC,aAAA,CAACT,cAAA,CAAAQ,OAAQ;IAACF,OAAO,EAAEA,OAAQ;IAACC,SAAS,EAAEA;EAAU,GAC5CH,QACK,CAAC;AAEnB,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["React","Mosaic","props","createElement","Fragment","children"],"sources":["Mosaic.tsx"],"sourcesContent":["import React from \"react\";\n\nexport interface MosaicProps extends Record<string, any> {\n children: React.ReactNode;\n}\n\n/**\n * @deprecated This component is deprecated and will be removed in future releases.\n * Please implement your own `Mosaic` component or reach out on Slack.\n */\nconst Mosaic = (props: MosaicProps) => {\n return <>{props.children}</>;\n};\n\nexport { Mosaic };\n"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AAMzB;AACA;AACA;AACA;AACA,MAAMC,MAAM,GAAIC,KAAkB,IAAK;EACnC,oBAAOF,KAAA,CAAAG,aAAA,CAAAH,KAAA,CAAAI,QAAA,QAAGF,KAAK,CAACG,QAAW,CAAC;AAChC,CAAC;AAED,SAASJ,MAAM","ignoreList":[]}
package/Mosaic/index.js CHANGED
@@ -1,18 +1,3 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- var _Mosaic = require("./Mosaic");
7
- Object.keys(_Mosaic).forEach(function (key) {
8
- if (key === "default" || key === "__esModule") return;
9
- if (key in exports && exports[key] === _Mosaic[key]) return;
10
- Object.defineProperty(exports, key, {
11
- enumerable: true,
12
- get: function get() {
13
- return _Mosaic[key];
14
- }
15
- });
16
- });
1
+ export * from "./Mosaic";
17
2
 
18
3
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["_Mosaic","require","Object","keys","forEach","key","exports","defineProperty","enumerable","get"],"sources":["index.ts"],"sourcesContent":["export * from \"./Mosaic\";\n"],"mappings":";;;;;AAAA,IAAAA,OAAA,GAAAC,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAH,OAAA,EAAAI,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAL,OAAA,CAAAK,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,IAAA;MAAA,OAAAT,OAAA,CAAAK,GAAA;IAAA;EAAA;AAAA","ignoreList":[]}
1
+ {"version":3,"names":[],"sources":["index.ts"],"sourcesContent":["export * from \"./Mosaic\";\n"],"mappings":"AAAA","ignoreList":[]}
@@ -1,4 +1,4 @@
1
- import React from "react";
1
+ import * as React from "react";
2
2
  interface CircularProgressProps {
3
3
  label?: React.ReactNode;
4
4
  size?: number;
@@ -7,5 +7,13 @@ interface CircularProgressProps {
7
7
  visible?: boolean;
8
8
  style?: React.CSSProperties;
9
9
  }
10
- declare const CircularProgress: (props: CircularProgressProps) => React.JSX.Element;
10
+ /**
11
+ * @deprecated This component is deprecated and will be removed in future releases.
12
+ * Please use the `Loader` or `OverlayLoader` components from the `@webiny/admin-ui` package instead.
13
+ */
14
+ declare const CircularProgress: {
15
+ (props: CircularProgressProps): React.JSX.Element;
16
+ displayName: string;
17
+ };
18
+ export { CircularProgress };
11
19
  export default CircularProgress;