@onewelcome/react-lib-components 6.6.0 → 6.7.1

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 (243) hide show
  1. package/dist/cjs/DataGrid/DataGrid.module.cjs.js +1 -1
  2. package/dist/cjs/DataGrid/DataGridBody/DataGridCell.cjs.js +1 -1
  3. package/dist/cjs/DataGrid/DataGridBody/DataGridCell.cjs.js.map +1 -1
  4. package/dist/cjs/DataGrid/DataGridBody/DataGridCell.module.cjs.js +1 -1
  5. package/dist/cjs/DataGrid/DataGridBody/DataGridRow.module.cjs.js +1 -1
  6. package/dist/cjs/DataGrid/DataGridHeader/DataGridHeader.cjs.js +1 -1
  7. package/dist/cjs/DataGrid/DataGridHeader/DataGridHeader.cjs.js.map +1 -1
  8. package/dist/cjs/DataGrid/DataGridHeader/DataGridHeader.module.cjs.js +1 -1
  9. package/dist/cjs/DataGrid/DataGridHeader/DataGridHeaderCell.module.cjs.js +1 -1
  10. package/dist/cjs/Form/FileUpload/FileItem/FileItem.cjs.js +1 -1
  11. package/dist/cjs/Form/FileUpload/FileItem/FileItem.cjs.js.map +1 -1
  12. package/dist/cjs/Form/FileUpload/FileItem/FileItem.module.cjs.js +1 -1
  13. package/dist/cjs/Form/FileUpload/FileUpload.cjs.js +1 -1
  14. package/dist/cjs/Form/FileUpload/FileUpload.cjs.js.map +1 -1
  15. package/dist/cjs/Form/FileUpload/FileUpload.module.cjs.js +1 -1
  16. package/dist/cjs/Icon/Icon.cjs.js +1 -1
  17. package/dist/cjs/Icon/Icon.cjs.js.map +1 -1
  18. package/dist/cjs/Icon/Icon.module.cjs.js +1 -1
  19. package/dist/cjs/Layout/ContentHeader/ContentHeader.cjs.js +2 -0
  20. package/dist/cjs/Layout/ContentHeader/ContentHeader.cjs.js.map +1 -0
  21. package/dist/cjs/Layout/ContentHeader/ContentHeader.module.cjs.js +2 -0
  22. package/dist/cjs/Layout/ContentHeader/ContentHeader.module.cjs.js.map +1 -0
  23. package/dist/cjs/Layout/FormPage/FormWithStepper/FormSection/FormSection.cjs.js +2 -0
  24. package/dist/cjs/Layout/FormPage/FormWithStepper/FormSection/FormSection.cjs.js.map +1 -0
  25. package/dist/cjs/Layout/FormPage/FormWithStepper/FormSection/FormSection.module.cjs.js +2 -0
  26. package/dist/cjs/Layout/FormPage/FormWithStepper/FormSection/FormSection.module.cjs.js.map +1 -0
  27. package/dist/cjs/Layout/FormPage/FormWithStepper/FormStepper/FormStepper.cjs.js +2 -0
  28. package/dist/cjs/Layout/FormPage/FormWithStepper/FormStepper/FormStepper.cjs.js.map +1 -0
  29. package/dist/cjs/Layout/FormPage/FormWithStepper/FormStepper/FormStepper.module.cjs.js +2 -0
  30. package/dist/cjs/Layout/FormPage/FormWithStepper/FormStepper/FormStepper.module.cjs.js.map +1 -0
  31. package/dist/cjs/Layout/FormPage/FormWithStepper/FormWithStepper.cjs.js +2 -0
  32. package/dist/cjs/Layout/FormPage/FormWithStepper/FormWithStepper.cjs.js.map +1 -0
  33. package/dist/cjs/Layout/FormPage/FormWithStepper/FormWithStepper.module.cjs.js +2 -0
  34. package/dist/cjs/Layout/FormPage/FormWithStepper/FormWithStepper.module.cjs.js.map +1 -0
  35. package/dist/cjs/Notifications/Alert/AlertContainer/AlertContainer.cjs.js +2 -0
  36. package/dist/cjs/Notifications/Alert/AlertContainer/AlertContainer.cjs.js.map +1 -0
  37. package/dist/cjs/Notifications/Alert/AlertContainer/AlertContainer.module.cjs.js +2 -0
  38. package/dist/cjs/Notifications/Alert/AlertContainer/AlertContainer.module.cjs.js.map +1 -0
  39. package/dist/cjs/Notifications/Alert/AlertContainer/useAlertContainerHeightAnimation.cjs.js +2 -0
  40. package/dist/cjs/Notifications/Alert/AlertContainer/useAlertContainerHeightAnimation.cjs.js.map +1 -0
  41. package/dist/cjs/Notifications/Alert/AlertItem/AlertItem.cjs.js +2 -0
  42. package/dist/cjs/Notifications/Alert/AlertItem/AlertItem.cjs.js.map +1 -0
  43. package/dist/cjs/Notifications/Alert/AlertItem/AlertItem.module.cjs.js +2 -0
  44. package/dist/cjs/Notifications/Alert/AlertItem/AlertItem.module.cjs.js.map +1 -0
  45. package/dist/cjs/Notifications/Alert/AlertProvider/AlertContext.cjs.js +2 -0
  46. package/dist/cjs/Notifications/Alert/AlertProvider/AlertContext.cjs.js.map +1 -0
  47. package/dist/cjs/Notifications/Alert/AlertProvider/AlertProvider.cjs.js +2 -0
  48. package/dist/cjs/Notifications/Alert/AlertProvider/AlertProvider.cjs.js.map +1 -0
  49. package/dist/cjs/Notifications/Alert/useAlert.cjs.js +2 -0
  50. package/dist/cjs/Notifications/Alert/useAlert.cjs.js.map +1 -0
  51. package/dist/cjs/Notifications/Snackbar/SnackbarContainer/SnackbarContainer.cjs.js.map +1 -1
  52. package/dist/cjs/Notifications/Snackbar/SnackbarItem/SnackbarItem.cjs.js.map +1 -1
  53. package/dist/cjs/Notifications/Snackbar/SnackbarProvider/SnackbarProvider.cjs.js.map +1 -1
  54. package/dist/cjs/Notifications/Snackbar/SnackbarProvider/SnackbarStateProvider.cjs.js.map +1 -1
  55. package/dist/cjs/Notifications/Snackbar/interfaces.cjs.js.map +1 -1
  56. package/dist/cjs/Notifications/Snackbar/useSnackbar.cjs.js.map +1 -1
  57. package/dist/cjs/Pagination/Pagination.cjs.js +1 -1
  58. package/dist/cjs/Pagination/Pagination.cjs.js.map +1 -1
  59. package/dist/cjs/Pagination/Pagination.module.cjs.js +1 -1
  60. package/dist/cjs/_BaseStyling_/BaseStyling.cjs.js +1 -1
  61. package/dist/cjs/_BaseStyling_/BaseStyling.cjs.js.map +1 -1
  62. package/dist/cjs/admin/layout/MicrofrontendContainer/MicrofrontendContainer.cjs.js +2 -0
  63. package/dist/cjs/admin/layout/MicrofrontendContainer/MicrofrontendContainer.cjs.js.map +1 -0
  64. package/dist/cjs/admin/layout/MicrofrontendContainer/MicrofrontendContainer.module.cjs.js +2 -0
  65. package/dist/cjs/admin/layout/MicrofrontendContainer/MicrofrontendContainer.module.cjs.js.map +1 -0
  66. package/dist/cjs/src/components/Form/FileUpload/FileItem/FileItem.d.ts +10 -0
  67. package/dist/cjs/src/components/Form/FileUpload/FileUpload.d.ts +3 -0
  68. package/dist/cjs/src/components/Icon/Icon.d.ts +5 -1
  69. package/dist/cjs/src/components/Layout/ContentHeader/ContentHeader.d.ts +10 -0
  70. package/dist/cjs/src/components/Layout/ContentHeader/ContentHeader.test.d.ts +1 -0
  71. package/dist/cjs/src/components/Layout/FormPage/FormWithStepper/FormSection/FormSection.d.ts +7 -0
  72. package/dist/cjs/src/components/Layout/FormPage/FormWithStepper/FormSection/FormSection.test.d.ts +1 -0
  73. package/dist/cjs/src/components/Layout/FormPage/FormWithStepper/FormStepper/FormStepper.d.ts +10 -0
  74. package/dist/cjs/src/components/Layout/FormPage/FormWithStepper/FormStepper/FormStepper.test.d.ts +1 -0
  75. package/dist/cjs/src/components/Layout/FormPage/FormWithStepper/FormWithStepper.d.ts +6 -0
  76. package/dist/cjs/src/components/Layout/FormPage/FormWithStepper/FormWithStepper.test.d.ts +1 -0
  77. package/dist/cjs/src/components/Notifications/Alert/AlertContainer/AlertContainer.d.ts +12 -0
  78. package/dist/cjs/src/components/Notifications/Alert/AlertContainer/AlertContainer.test.d.ts +1 -0
  79. package/dist/cjs/src/components/Notifications/Alert/AlertContainer/useAlertContainerHeightAnimation.d.ts +4 -0
  80. package/dist/cjs/src/components/Notifications/Alert/AlertItem/AlertItem.d.ts +22 -0
  81. package/dist/cjs/src/components/Notifications/Alert/AlertItem/AlertItem.test.d.ts +1 -0
  82. package/dist/cjs/src/components/Notifications/Alert/AlertProvider/AlertContext.d.ts +13 -0
  83. package/dist/cjs/src/components/Notifications/Alert/AlertProvider/AlertProvider.d.ts +22 -0
  84. package/dist/cjs/src/components/Notifications/Alert/AlertProvider/AlertProvider.test.d.ts +1 -0
  85. package/dist/cjs/src/components/Notifications/Alert/useAlert.d.ts +7 -0
  86. package/dist/cjs/src/components/Notifications/Alert/useAlert.test.d.ts +1 -0
  87. package/dist/cjs/src/components/Notifications/Snackbar/SnackbarContainer/SnackbarContainer.d.ts +9 -0
  88. package/dist/cjs/src/components/Notifications/Snackbar/SnackbarItem/SnackbarItem.d.ts +6 -0
  89. package/dist/cjs/src/components/Notifications/Snackbar/SnackbarProvider/SnackbarProvider.d.ts +9 -0
  90. package/dist/cjs/src/components/Notifications/Snackbar/SnackbarProvider/SnackbarStateProvider.d.ts +9 -0
  91. package/dist/cjs/src/components/Notifications/Snackbar/interfaces.d.ts +18 -0
  92. package/dist/cjs/src/components/Notifications/Snackbar/useSnackbar.d.ts +3 -0
  93. package/dist/cjs/src/components/_BaseStyling_/BaseStyling.d.ts +40 -0
  94. package/dist/cjs/src/components/admin/layout/MicrofrontendContainer/MicrofrontendContainer.d.ts +8 -0
  95. package/dist/cjs/src/index.cjs.js +1 -1
  96. package/dist/cjs/src/index.d.ts +18 -0
  97. package/dist/esm/DataGrid/DataGrid.module.esm.js +1 -1
  98. package/dist/esm/DataGrid/DataGridBody/DataGridCell.esm.js +1 -1
  99. package/dist/esm/DataGrid/DataGridBody/DataGridCell.esm.js.map +1 -1
  100. package/dist/esm/DataGrid/DataGridBody/DataGridCell.module.esm.js +1 -1
  101. package/dist/esm/DataGrid/DataGridBody/DataGridRow.module.esm.js +1 -1
  102. package/dist/esm/DataGrid/DataGridHeader/DataGridHeader.esm.js +1 -1
  103. package/dist/esm/DataGrid/DataGridHeader/DataGridHeader.esm.js.map +1 -1
  104. package/dist/esm/DataGrid/DataGridHeader/DataGridHeader.module.esm.js +1 -1
  105. package/dist/esm/DataGrid/DataGridHeader/DataGridHeaderCell.module.esm.js +1 -1
  106. package/dist/esm/Form/FileUpload/FileItem/FileItem.esm.js +1 -1
  107. package/dist/esm/Form/FileUpload/FileItem/FileItem.esm.js.map +1 -1
  108. package/dist/esm/Form/FileUpload/FileItem/FileItem.module.esm.js +1 -1
  109. package/dist/esm/Form/FileUpload/FileUpload.esm.js +1 -1
  110. package/dist/esm/Form/FileUpload/FileUpload.esm.js.map +1 -1
  111. package/dist/esm/Form/FileUpload/FileUpload.module.esm.js +1 -1
  112. package/dist/esm/Icon/Icon.esm.js +1 -1
  113. package/dist/esm/Icon/Icon.esm.js.map +1 -1
  114. package/dist/esm/Icon/Icon.module.esm.js +1 -1
  115. package/dist/esm/Layout/ContentHeader/ContentHeader.esm.js +2 -0
  116. package/dist/esm/Layout/ContentHeader/ContentHeader.esm.js.map +1 -0
  117. package/dist/esm/Layout/ContentHeader/ContentHeader.module.esm.js +2 -0
  118. package/dist/esm/Layout/ContentHeader/ContentHeader.module.esm.js.map +1 -0
  119. package/dist/esm/Layout/FormPage/FormWithStepper/FormSection/FormSection.esm.js +2 -0
  120. package/dist/esm/Layout/FormPage/FormWithStepper/FormSection/FormSection.esm.js.map +1 -0
  121. package/dist/esm/Layout/FormPage/FormWithStepper/FormSection/FormSection.module.esm.js +2 -0
  122. package/dist/esm/Layout/FormPage/FormWithStepper/FormSection/FormSection.module.esm.js.map +1 -0
  123. package/dist/esm/Layout/FormPage/FormWithStepper/FormStepper/FormStepper.esm.js +2 -0
  124. package/dist/esm/Layout/FormPage/FormWithStepper/FormStepper/FormStepper.esm.js.map +1 -0
  125. package/dist/esm/Layout/FormPage/FormWithStepper/FormStepper/FormStepper.module.esm.js +2 -0
  126. package/dist/esm/Layout/FormPage/FormWithStepper/FormStepper/FormStepper.module.esm.js.map +1 -0
  127. package/dist/esm/Layout/FormPage/FormWithStepper/FormWithStepper.esm.js +2 -0
  128. package/dist/esm/Layout/FormPage/FormWithStepper/FormWithStepper.esm.js.map +1 -0
  129. package/dist/esm/Layout/FormPage/FormWithStepper/FormWithStepper.module.esm.js +2 -0
  130. package/dist/esm/Layout/FormPage/FormWithStepper/FormWithStepper.module.esm.js.map +1 -0
  131. package/dist/esm/Notifications/Alert/AlertContainer/AlertContainer.esm.js +2 -0
  132. package/dist/esm/Notifications/Alert/AlertContainer/AlertContainer.esm.js.map +1 -0
  133. package/dist/esm/Notifications/Alert/AlertContainer/AlertContainer.module.esm.js +2 -0
  134. package/dist/esm/Notifications/Alert/AlertContainer/AlertContainer.module.esm.js.map +1 -0
  135. package/dist/esm/Notifications/Alert/AlertContainer/useAlertContainerHeightAnimation.esm.js +2 -0
  136. package/dist/esm/Notifications/Alert/AlertContainer/useAlertContainerHeightAnimation.esm.js.map +1 -0
  137. package/dist/esm/Notifications/Alert/AlertItem/AlertItem.esm.js +2 -0
  138. package/dist/esm/Notifications/Alert/AlertItem/AlertItem.esm.js.map +1 -0
  139. package/dist/esm/Notifications/Alert/AlertItem/AlertItem.module.esm.js +2 -0
  140. package/dist/esm/Notifications/Alert/AlertItem/AlertItem.module.esm.js.map +1 -0
  141. package/dist/esm/Notifications/Alert/AlertProvider/AlertContext.esm.js +2 -0
  142. package/dist/esm/Notifications/Alert/AlertProvider/AlertContext.esm.js.map +1 -0
  143. package/dist/esm/Notifications/Alert/AlertProvider/AlertProvider.esm.js +2 -0
  144. package/dist/esm/Notifications/Alert/AlertProvider/AlertProvider.esm.js.map +1 -0
  145. package/dist/esm/Notifications/Alert/useAlert.esm.js +2 -0
  146. package/dist/esm/Notifications/Alert/useAlert.esm.js.map +1 -0
  147. package/dist/esm/Notifications/Snackbar/SnackbarContainer/SnackbarContainer.esm.js.map +1 -1
  148. package/dist/esm/Notifications/Snackbar/SnackbarItem/SnackbarItem.esm.js.map +1 -1
  149. package/dist/esm/Notifications/Snackbar/SnackbarProvider/SnackbarProvider.esm.js.map +1 -1
  150. package/dist/esm/Notifications/Snackbar/SnackbarProvider/SnackbarStateProvider.esm.js.map +1 -1
  151. package/dist/esm/Notifications/Snackbar/interfaces.esm.js.map +1 -1
  152. package/dist/esm/Notifications/Snackbar/useSnackbar.esm.js.map +1 -1
  153. package/dist/esm/Pagination/Pagination.esm.js +1 -1
  154. package/dist/esm/Pagination/Pagination.esm.js.map +1 -1
  155. package/dist/esm/Pagination/Pagination.module.esm.js +1 -1
  156. package/dist/esm/_BaseStyling_/BaseStyling.esm.js +1 -1
  157. package/dist/esm/_BaseStyling_/BaseStyling.esm.js.map +1 -1
  158. package/dist/esm/admin/layout/MicrofrontendContainer/MicrofrontendContainer.esm.js +2 -0
  159. package/dist/esm/admin/layout/MicrofrontendContainer/MicrofrontendContainer.esm.js.map +1 -0
  160. package/dist/esm/admin/layout/MicrofrontendContainer/MicrofrontendContainer.module.esm.js +2 -0
  161. package/dist/esm/admin/layout/MicrofrontendContainer/MicrofrontendContainer.module.esm.js.map +1 -0
  162. package/dist/esm/src/components/Form/FileUpload/FileItem/FileItem.d.ts +10 -0
  163. package/dist/esm/src/components/Form/FileUpload/FileUpload.d.ts +3 -0
  164. package/dist/esm/src/components/Icon/Icon.d.ts +5 -1
  165. package/dist/esm/src/components/Layout/ContentHeader/ContentHeader.d.ts +10 -0
  166. package/dist/esm/src/components/Layout/ContentHeader/ContentHeader.test.d.ts +1 -0
  167. package/dist/esm/src/components/Layout/FormPage/FormWithStepper/FormSection/FormSection.d.ts +7 -0
  168. package/dist/esm/src/components/Layout/FormPage/FormWithStepper/FormSection/FormSection.test.d.ts +1 -0
  169. package/dist/esm/src/components/Layout/FormPage/FormWithStepper/FormStepper/FormStepper.d.ts +10 -0
  170. package/dist/esm/src/components/Layout/FormPage/FormWithStepper/FormStepper/FormStepper.test.d.ts +1 -0
  171. package/dist/esm/src/components/Layout/FormPage/FormWithStepper/FormWithStepper.d.ts +6 -0
  172. package/dist/esm/src/components/Layout/FormPage/FormWithStepper/FormWithStepper.test.d.ts +1 -0
  173. package/dist/esm/src/components/Notifications/Alert/AlertContainer/AlertContainer.d.ts +12 -0
  174. package/dist/esm/src/components/Notifications/Alert/AlertContainer/AlertContainer.test.d.ts +1 -0
  175. package/dist/esm/src/components/Notifications/Alert/AlertContainer/useAlertContainerHeightAnimation.d.ts +4 -0
  176. package/dist/esm/src/components/Notifications/Alert/AlertItem/AlertItem.d.ts +22 -0
  177. package/dist/esm/src/components/Notifications/Alert/AlertItem/AlertItem.test.d.ts +1 -0
  178. package/dist/esm/src/components/Notifications/Alert/AlertProvider/AlertContext.d.ts +13 -0
  179. package/dist/esm/src/components/Notifications/Alert/AlertProvider/AlertProvider.d.ts +22 -0
  180. package/dist/esm/src/components/Notifications/Alert/AlertProvider/AlertProvider.test.d.ts +1 -0
  181. package/dist/esm/src/components/Notifications/Alert/useAlert.d.ts +7 -0
  182. package/dist/esm/src/components/Notifications/Alert/useAlert.test.d.ts +1 -0
  183. package/dist/esm/src/components/Notifications/Snackbar/SnackbarContainer/SnackbarContainer.d.ts +9 -0
  184. package/dist/esm/src/components/Notifications/Snackbar/SnackbarItem/SnackbarItem.d.ts +6 -0
  185. package/dist/esm/src/components/Notifications/Snackbar/SnackbarProvider/SnackbarProvider.d.ts +9 -0
  186. package/dist/esm/src/components/Notifications/Snackbar/SnackbarProvider/SnackbarStateProvider.d.ts +9 -0
  187. package/dist/esm/src/components/Notifications/Snackbar/interfaces.d.ts +18 -0
  188. package/dist/esm/src/components/Notifications/Snackbar/useSnackbar.d.ts +3 -0
  189. package/dist/esm/src/components/_BaseStyling_/BaseStyling.d.ts +40 -0
  190. package/dist/esm/src/components/admin/layout/MicrofrontendContainer/MicrofrontendContainer.d.ts +8 -0
  191. package/dist/esm/src/index.d.ts +18 -0
  192. package/dist/esm/src/index.esm.js +1 -1
  193. package/package.json +1 -1
  194. package/src/components/DataGrid/DataGrid.module.scss +2 -2
  195. package/src/components/DataGrid/DataGridBody/DataGridCell.module.scss +7 -2
  196. package/src/components/DataGrid/DataGridBody/DataGridCell.tsx +1 -1
  197. package/src/components/DataGrid/DataGridBody/DataGridRow.module.scss +10 -0
  198. package/src/components/DataGrid/DataGridBody/__snapshots__/DataGridBody.test.tsx.snap +16 -16
  199. package/src/components/DataGrid/DataGridHeader/DataGridHeader.module.scss +0 -10
  200. package/src/components/DataGrid/DataGridHeader/DataGridHeader.tsx +1 -1
  201. package/src/components/DataGrid/DataGridHeader/DataGridHeaderCell.module.scss +3 -3
  202. package/src/components/Form/FileUpload/FileItem/FileItem.module.scss +114 -3
  203. package/src/components/Form/FileUpload/FileItem/FileItem.tsx +154 -47
  204. package/src/components/Form/FileUpload/FileUpload.module.scss +73 -16
  205. package/src/components/Form/FileUpload/FileUpload.tsx +82 -53
  206. package/src/components/Form/FormSection/FormSection.module.scss +12 -0
  207. package/src/components/Icon/Icon.module.scss +16 -1
  208. package/src/components/Icon/Icon.tsx +5 -1
  209. package/src/components/Layout/ContentHeader/ContentHeader.module.scss +44 -0
  210. package/src/components/Layout/ContentHeader/ContentHeader.tsx +70 -0
  211. package/src/components/Layout/FormPage/FormWithStepper/FormSection/FormSection.module.scss +12 -0
  212. package/src/components/Layout/FormPage/FormWithStepper/FormSection/FormSection.tsx +53 -0
  213. package/src/components/Layout/FormPage/FormWithStepper/FormStepper/FormStepper.module.scss +25 -0
  214. package/src/components/Layout/FormPage/FormWithStepper/FormStepper/FormStepper.tsx +54 -0
  215. package/src/components/Layout/FormPage/FormWithStepper/FormWithStepper.module.scss +39 -0
  216. package/src/components/Layout/FormPage/FormWithStepper/FormWithStepper.tsx +34 -0
  217. package/src/components/Notifications/Alert/AlertContainer/AlertContainer.module.scss +56 -0
  218. package/src/components/Notifications/Alert/AlertContainer/AlertContainer.tsx +52 -0
  219. package/src/components/Notifications/Alert/AlertContainer/useAlertContainerHeightAnimation.ts +47 -0
  220. package/src/components/Notifications/Alert/AlertItem/AlertItem.module.scss +277 -0
  221. package/src/components/Notifications/Alert/AlertItem/AlertItem.tsx +214 -0
  222. package/src/components/Notifications/Alert/AlertProvider/AlertContext.ts +42 -0
  223. package/src/components/Notifications/Alert/AlertProvider/AlertProvider.tsx +173 -0
  224. package/src/components/Notifications/Alert/useAlert.ts +30 -0
  225. package/src/components/Notifications/Snackbar/SnackbarContainer/SnackbarContainer.tsx +9 -0
  226. package/src/components/Notifications/Snackbar/SnackbarItem/SnackbarItem.tsx +6 -0
  227. package/src/components/Notifications/Snackbar/SnackbarProvider/SnackbarProvider.tsx +9 -0
  228. package/src/components/Notifications/Snackbar/SnackbarProvider/SnackbarStateProvider.tsx +9 -0
  229. package/src/components/Notifications/Snackbar/interfaces.ts +18 -0
  230. package/src/components/Notifications/Snackbar/useSnackbar.ts +3 -0
  231. package/src/components/Pagination/Pagination.module.scss +4 -6
  232. package/src/components/Pagination/Pagination.tsx +3 -1
  233. package/src/components/_BaseStyling_/BaseStyling.tsx +78 -1
  234. package/src/components/admin/layout/MicrofrontendContainer/MicrofrontendContainer.module.scss +25 -0
  235. package/src/components/admin/layout/MicrofrontendContainer/MicrofrontendContainer.tsx +47 -0
  236. package/src/font/icomoon.eot +0 -0
  237. package/src/font/icomoon.svg +3 -0
  238. package/src/font/icomoon.ttf +0 -0
  239. package/src/font/icomoon.woff +0 -0
  240. package/src/font/selection.json +1 -1
  241. package/src/index.ts +25 -0
  242. package/src/mixins.module.scss +7 -0
  243. package/src/variables.scss +1 -0
@@ -0,0 +1,277 @@
1
+ /*!
2
+ * Copyright 2022 OneWelcome B.V.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+
17
+ @use "../../../../mixins.module.scss";
18
+
19
+ .alert {
20
+ padding: 1rem 0.875rem;
21
+ border-radius: var(--alert-border-radius);
22
+ display: flex;
23
+ gap: 0.5rem;
24
+ align-items: center;
25
+ width: 100%;
26
+ box-sizing: border-box;
27
+ flex-grow: 0;
28
+
29
+ &.neutral {
30
+ background-color: var(--alert-neutral-background-color);
31
+ border-radius: var(--alert-border-radius);
32
+
33
+ &.emph-low {
34
+ color: unset;
35
+ }
36
+
37
+ &.emph-medium {
38
+ @include mixins.alertBorder(var(--alert-neutral-inverted-color));
39
+ }
40
+
41
+ &.emph-high {
42
+ background-color: var(--alert-neutral-inverted-color);
43
+
44
+ .content,
45
+ .title,
46
+ .close-btn,
47
+ .icon,
48
+ .action-button {
49
+ color: var(--alert-text-inverted-color);
50
+ }
51
+ }
52
+ }
53
+
54
+ &.informative {
55
+ background-color: var(--alert-info-background-color);
56
+ border-radius: var(--alert-border-radius);
57
+
58
+ &.emph-low {
59
+ color: unset;
60
+ }
61
+
62
+ &.emph-medium {
63
+ @include mixins.alertBorder(var(--alert-info-inverted-color));
64
+ }
65
+
66
+ &.emph-high {
67
+ background-color: var(--alert-info-inverted-color);
68
+
69
+ .content,
70
+ .title,
71
+ .close-btn,
72
+ .icon,
73
+ .action-button {
74
+ color: var(--alert-text-inverted-color);
75
+ }
76
+ }
77
+ }
78
+
79
+ &.success {
80
+ background-color: var(--alert-success-background-color);
81
+ border-radius: var(--alert-border-radius);
82
+
83
+ &.emph-low .icon {
84
+ color: var(--alert-success-inverted-color);
85
+ }
86
+
87
+ &.emph-medium {
88
+ @include mixins.alertBorder(var(--alert-success-inverted-color));
89
+
90
+ .icon {
91
+ color: var(--alert-success-inverted-color);
92
+ }
93
+ }
94
+
95
+ &.emph-high {
96
+ background-color: var(--alert-success-inverted-color);
97
+
98
+ .content,
99
+ .title,
100
+ .close-btn,
101
+ .icon,
102
+ .action-button {
103
+ color: var(--alert-text-inverted-color);
104
+ }
105
+ }
106
+ }
107
+
108
+ &.warning {
109
+ background-color: var(--alert-warning-background-color);
110
+ border-radius: var(--alert-border-radius);
111
+
112
+ &.emph-low .icon {
113
+ color: var(--alert-warning-inverted-color);
114
+ }
115
+
116
+ &.emph-medium {
117
+ @include mixins.alertBorder(var(--alert-warning-inverted-color));
118
+
119
+ .icon {
120
+ color: var(--alert-warning-inverted-color);
121
+ }
122
+ }
123
+
124
+ &.emph-high {
125
+ background-color: var(--alert-warning-inverted-color);
126
+
127
+ .content,
128
+ .title,
129
+ .close-btn,
130
+ .icon,
131
+ .action-button {
132
+ color: var(--alert-text-inverted-color);
133
+ }
134
+ }
135
+ }
136
+
137
+ &.error {
138
+ background-color: var(--alert-error-background-color);
139
+ border-radius: var(--alert-border-radius);
140
+
141
+ &.emph-low .icon {
142
+ color: var(--alert-error-inverted-color);
143
+ }
144
+
145
+ &.emph-medium {
146
+ @include mixins.alertBorder(var(--alert-error-inverted-color));
147
+
148
+ .icon {
149
+ color: var(--alert-error-inverted-color);
150
+ }
151
+ }
152
+
153
+ &.emph-high {
154
+ background-color: var(--alert-error-inverted-color);
155
+
156
+ .content,
157
+ .title,
158
+ .close-btn,
159
+ .icon,
160
+ .action-button {
161
+ color: var(--alert-text-inverted-color);
162
+ }
163
+ }
164
+ }
165
+
166
+ & + & {
167
+ margin-top: 0.5rem;
168
+ }
169
+
170
+ .close-btn {
171
+ color: var(--alert-text-color);
172
+ align-self: center;
173
+ width: 2.5rem;
174
+ height: 2.5rem;
175
+ margin: -0.5rem 0;
176
+ flex-shrink: 0;
177
+ border: 0;
178
+
179
+ span {
180
+ font-size: 0.875rem;
181
+ }
182
+
183
+ &:not(:disabled):hover,
184
+ &:not(:disabled):focus {
185
+ background-color: var(--color-black10);
186
+ }
187
+
188
+ &:not(:disabled):active {
189
+ background-color: var(--color-black20);
190
+ }
191
+ }
192
+
193
+ .icon {
194
+ color: var(--alert-text-color);
195
+ font-size: 1rem;
196
+ height: 1.25rem;
197
+ display: inline-flex;
198
+ align-items: center;
199
+ align-self: flex-start;
200
+ }
201
+
202
+ .title {
203
+ color: var(--alert-text-color);
204
+ flex: 1;
205
+ font-size: 0.875rem;
206
+ line-height: 1.25rem;
207
+ margin-bottom: 0.25rem;
208
+ display: block;
209
+ }
210
+
211
+ .outer-content-wrapper {
212
+ display: flex;
213
+ gap: 0.5rem;
214
+ flex-grow: 1;
215
+ }
216
+
217
+ .content-wrapper {
218
+ flex-grow: 1;
219
+ padding-left: 0.125rem;
220
+ }
221
+
222
+ .content {
223
+ color: var(--alert-text-color);
224
+ font-size: 0.875rem;
225
+ line-height: 1.25rem;
226
+ margin-bottom: 0;
227
+ }
228
+
229
+ .actions {
230
+ text-align: right;
231
+ align-self: center;
232
+ }
233
+
234
+ .action-button {
235
+ border-width: var(--button-border-width);
236
+ border-style: var(--button-border-style);
237
+ border-radius: var(--button-border-radius);
238
+ white-space: nowrap;
239
+ font-size: 0.875rem;
240
+ line-height: var(--button-font-size);
241
+ font-weight: 400;
242
+ margin: -0.5rem 0;
243
+ padding: 0.625rem 1.25rem;
244
+ cursor: pointer;
245
+ transition:
246
+ color,
247
+ background-color,
248
+ border-color 0.2s ease-in-out;
249
+ font-family: var(--font-family);
250
+ color: var(--alert-text-color);
251
+ background-color: transparent;
252
+ border-color: transparent;
253
+
254
+ &:disabled {
255
+ color: var(--greyed-out);
256
+ cursor: not-allowed;
257
+ }
258
+
259
+ @include mixins.focusVisibleOutline();
260
+
261
+ &:not(:disabled):hover,
262
+ &:not(:disabled):focus {
263
+ background-color: var(--color-black10);
264
+ }
265
+
266
+ &:not(:disabled):active {
267
+ background-color: var(--color-black20);
268
+ }
269
+ }
270
+ }
271
+
272
+ @media only screen and (min-width: 37.5em) {
273
+ .alert {
274
+ width: min-content;
275
+ min-width: 25rem;
276
+ }
277
+ }
@@ -0,0 +1,214 @@
1
+ /*
2
+ * Copyright 2022 OneWelcome B.V.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+
17
+ import React, { ButtonHTMLAttributes, useContext, useEffect, useRef } from "react";
18
+ import { IconButton } from "../../../Button/IconButton";
19
+ import { Icon, Icons } from "../../../Icon/Icon";
20
+ import classes from "./AlertItem.module.scss";
21
+ import readyclasses from "../../../../readyclasses.module.scss";
22
+ import { useAnimation } from "../../../../hooks/useAnimation";
23
+ import { Typography } from "../../../Typography/Typography";
24
+ import AlertContext from "../AlertProvider/AlertContext";
25
+
26
+ export const EMPHASES = ["low", "medium", "high"] as const;
27
+ export type Emphasis = (typeof EMPHASES)[keyof typeof EMPHASES];
28
+
29
+ export const VARIANTS = ["neutral", "informative", "success", "warning", "error"] as const;
30
+ export type Variant = (typeof VARIANTS)[keyof typeof VARIANTS];
31
+
32
+ export type Actions = (ButtonHTMLAttributes<HTMLButtonElement> & { label: string })[];
33
+
34
+ export interface Props {
35
+ id: string;
36
+ title?: string;
37
+ content?: string;
38
+ duration?: number;
39
+ emphasis?: Emphasis;
40
+ variant?: Variant;
41
+ className?: string;
42
+ onClose?: () => void;
43
+ closeButtonTitle?: string;
44
+ actions?: Actions;
45
+ wasShown?: boolean;
46
+ }
47
+
48
+ const useRegisterAlertHeight = (
49
+ singleAlertRef: React.RefObject<HTMLDivElement>,
50
+ alertId: string
51
+ ) => {
52
+ const ctx = useContext(AlertContext);
53
+
54
+ useEffect(() => {
55
+ if (singleAlertRef.current) {
56
+ ctx.setAlertHeight(alertId, singleAlertRef.current.getBoundingClientRect().height);
57
+ }
58
+ }, [singleAlertRef.current]);
59
+ };
60
+
61
+ let actionButtonKeyCounter = 1;
62
+ export const AlertItem = ({
63
+ id,
64
+ title,
65
+ duration,
66
+ variant = "neutral",
67
+ emphasis = "low",
68
+ content,
69
+ className,
70
+ actions = [],
71
+ onClose,
72
+ closeButtonTitle,
73
+ wasShown
74
+ }: Props) => {
75
+ const timerHandler = useRef<ReturnType<typeof setTimeout>>();
76
+ const onAnimationEnd = () => {
77
+ onClose?.();
78
+ };
79
+ const { ref, animationStarted, startAnimation } = useAnimation<HTMLDivElement>(onAnimationEnd);
80
+
81
+ useRegisterAlertHeight(ref, id);
82
+
83
+ useEffect(() => {
84
+ if (duration && duration > 0) {
85
+ timerHandler.current = setTimeout(() => startAnimation(), duration);
86
+ }
87
+ if (ref) {
88
+ ref.current?.addEventListener("focus", onItemFocus);
89
+ ref.current?.addEventListener("blur", onItemBlur);
90
+ ref.current?.addEventListener("mouseenter", onItemFocus);
91
+ ref.current?.addEventListener("mouseleave", onItemBlur);
92
+ }
93
+ return () => {
94
+ timerHandler.current && clearTimeout(timerHandler.current);
95
+ };
96
+ }, []);
97
+
98
+ const onItemFocus = () => {
99
+ timerHandler.current && clearTimeout(timerHandler.current);
100
+ };
101
+
102
+ const onItemBlur = () => {
103
+ if (duration && duration > 0) {
104
+ timerHandler.current = setTimeout(() => startAnimation(), duration);
105
+ }
106
+ };
107
+
108
+ const getVariantIcon = () => {
109
+ if (variant === "error") {
110
+ return Icons.ErrorAlt;
111
+ }
112
+
113
+ if (variant === "warning") {
114
+ return Icons.Warning;
115
+ }
116
+
117
+ return variant === "success" ? Icons.CheckmarkCircleAlt : Icons.InfoCircle;
118
+ };
119
+
120
+ const actionButtons = actions.map(actionProp => (
121
+ <button
122
+ key={`alert-action-button-${(actionButtonKeyCounter++).toString()}`}
123
+ {...actionProp}
124
+ onClick={e => {
125
+ onClose?.();
126
+ actionProp.onClick?.(e);
127
+ }}
128
+ className={classes["action-button"]}
129
+ >
130
+ {actionProp.label}
131
+ </button>
132
+ ));
133
+
134
+ const getAlertClasses = (): string => {
135
+ const alertClasses = [classes["alert"], classes[`${variant}`], classes[`emph-${emphasis}`]];
136
+ if (animationStarted) {
137
+ alertClasses.push(readyclasses["slide-out"]);
138
+ }
139
+ if (!animationStarted && !wasShown) {
140
+ alertClasses.push(readyclasses["slide-in"]);
141
+ }
142
+ if (className) {
143
+ alertClasses.push(className);
144
+ }
145
+ return alertClasses.join(" ");
146
+ };
147
+
148
+ const getAria = () => {
149
+ if (variant === "error" && (emphasis === "medium" || emphasis === "high")) {
150
+ return "assertive";
151
+ }
152
+ return "polite";
153
+ };
154
+
155
+ const getContentOrTitle = () => {
156
+ if (content) {
157
+ return content;
158
+ }
159
+ return title;
160
+ };
161
+
162
+ return (
163
+ <div
164
+ {...{ ["data-testid"]: "alert-container" }}
165
+ ref={ref}
166
+ aria-live={getAria()}
167
+ className={getAlertClasses()}
168
+ role="alert"
169
+ >
170
+ <div className={classes["outer-content-wrapper"]}>
171
+ <Icon icon={getVariantIcon()} className={classes["icon"]} />
172
+ <div className={classes["content-wrapper"]} role="log">
173
+ {!!title && !!content && (
174
+ <Typography
175
+ {...{ ["data-testid"]: "alert-title" }}
176
+ className={classes["title"]}
177
+ variant="body-bold"
178
+ tag="span"
179
+ >
180
+ {title}
181
+ </Typography>
182
+ )}
183
+ {(!!content || !!title) && (
184
+ <Typography
185
+ {...{ ["data-testid"]: "alert-content" }}
186
+ className={classes["content"]}
187
+ variant="body"
188
+ >
189
+ {getContentOrTitle()}
190
+ </Typography>
191
+ )}
192
+ </div>
193
+ </div>
194
+ {actionButtons.length > 0 && (
195
+ <div {...{ ["data-testid"]: "alert-actions" }} className={classes["actions"]}>
196
+ {actionButtons}
197
+ </div>
198
+ )}
199
+ {onClose && (
200
+ <IconButton
201
+ className={classes["close-btn"]}
202
+ onClick={e => {
203
+ e.stopPropagation();
204
+ startAnimation();
205
+ }}
206
+ title={closeButtonTitle}
207
+ {...{ ["data-testid"]: "alert-close" }}
208
+ >
209
+ <Icon icon={Icons.Times} />
210
+ </IconButton>
211
+ )}
212
+ </div>
213
+ );
214
+ };
@@ -0,0 +1,42 @@
1
+ /*
2
+ * Copyright 2022 OneWelcome B.V.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+
17
+ import { AlertEntry } from "./AlertProvider";
18
+ import { createContext } from "react";
19
+
20
+ export type AlertQueue = Omit<AlertEntry, "id">;
21
+
22
+ export interface AlertContextValue {
23
+ enqueueAlert: (entry: AlertQueue) => void;
24
+ enqueueInfoAlert: (entry: AlertQueue) => void;
25
+ enqueueSuccessAlert: (entry: AlertQueue) => void;
26
+ enqueueWarningAlert: (entry: AlertQueue) => void;
27
+ enqueueErrorAlert: (entry: AlertQueue) => void;
28
+ setAlertHeight: (id: string, height: number) => void;
29
+ alerts: AlertEntry[];
30
+ }
31
+
32
+ const AlertContext = createContext<AlertContextValue>({
33
+ enqueueAlert: entry => null,
34
+ enqueueInfoAlert: entry => null,
35
+ enqueueSuccessAlert: entry => null,
36
+ enqueueErrorAlert: entry => null,
37
+ enqueueWarningAlert: entry => null,
38
+ setAlertHeight: (id, height) => null,
39
+ alerts: []
40
+ });
41
+
42
+ export default AlertContext;
@@ -0,0 +1,173 @@
1
+ /*
2
+ * Copyright 2022 OneWelcome B.V.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+
17
+ import React, { ReactNode, useRef, useState, useMemo } from "react";
18
+ import { createPortal } from "react-dom";
19
+ import { Placement, AlertContainer } from "../AlertContainer/AlertContainer";
20
+ import { generateID } from "../../../../util/helper";
21
+ import { AlertItem, Props as AlertComponentProps, Variant } from "../AlertItem/AlertItem";
22
+ import { useGetDomRoot } from "../../../../hooks/useGetDomRoot";
23
+ import AlertContext, { AlertContextValue } from "./AlertContext";
24
+
25
+ /** Short msg is when only title is provided. Long one when content or/and actions are provided (or type is error). */
26
+ interface Duration {
27
+ long: number;
28
+ short: number;
29
+ }
30
+
31
+ export interface Props {
32
+ closeButtonTitle: string;
33
+ children?: ReactNode;
34
+ placement?: Placement;
35
+ stackSize?: number;
36
+ domRoot?: HTMLElement;
37
+ autoHideDuration?: Duration;
38
+ className?: string;
39
+ }
40
+
41
+ export type AlertEntry = AlertComponentProps & { height?: number };
42
+
43
+ export const AlertProvider = ({
44
+ closeButtonTitle,
45
+ placement = { vertical: "bottom", horizontal: "center" },
46
+ autoHideDuration = { long: 8000, short: 4000 },
47
+ stackSize = 3,
48
+ domRoot,
49
+ children,
50
+ className
51
+ }: Props) => {
52
+ const [alertEntries, setAlertEntries] = useState<AlertEntry[]>([]);
53
+ const wrappingDivRef = useRef(null);
54
+ const { root } = useGetDomRoot(domRoot, wrappingDivRef);
55
+
56
+ const getDuration = (entry: Omit<AlertEntry, "id">) => {
57
+ if (entry.variant === "error") {
58
+ return autoHideDuration.long;
59
+ }
60
+ if (entry.actions?.length) {
61
+ return autoHideDuration.long;
62
+ }
63
+ return autoHideDuration.short;
64
+ };
65
+
66
+ const buildEntryWithVariant = (arg: Omit<AlertEntry, "id">, variant?: Variant): AlertEntry => {
67
+ let closeTitle = closeButtonTitle;
68
+ if (arg.closeButtonTitle) {
69
+ closeTitle = arg.closeButtonTitle;
70
+ }
71
+ return {
72
+ ...arg,
73
+ variant: variant ?? arg.variant,
74
+ id: generateID(15, arg.content ?? arg.title),
75
+ duration: arg.duration ?? getDuration(arg),
76
+ closeButtonTitle: closeTitle
77
+ };
78
+ };
79
+
80
+ const enqueueAlert = (arg: Omit<AlertEntry, "id">) => {
81
+ const newEntry = buildEntryWithVariant(arg);
82
+ setAlertEntries(entries => [...entries, newEntry]);
83
+ };
84
+
85
+ const enqueueInfoAlert: AlertContextValue["enqueueInfoAlert"] = arg => {
86
+ const newEntry: AlertEntry = buildEntryWithVariant(arg, "informative");
87
+ setAlertEntries(entries => [...entries, newEntry]);
88
+ };
89
+
90
+ const enqueueSuccessAlert: AlertContextValue["enqueueSuccessAlert"] = arg => {
91
+ const newEntry: AlertEntry = buildEntryWithVariant(arg, "success");
92
+ setAlertEntries(entries => [...entries, newEntry]);
93
+ };
94
+
95
+ const enqueueWarningAlert: AlertContextValue["enqueueWarningAlert"] = arg => {
96
+ const newEntry: AlertEntry = buildEntryWithVariant(arg, "warning");
97
+ setAlertEntries(entries => [...entries, newEntry]);
98
+ };
99
+
100
+ const enqueueErrorAlert: AlertContextValue["enqueueErrorAlert"] = arg => {
101
+ const newEntry: AlertEntry = buildEntryWithVariant(arg, "error");
102
+ setAlertEntries(entries => [...entries, newEntry]);
103
+ };
104
+
105
+ const setAlertHeight = (id: string, height: number) => {
106
+ const newAlertsState = alertEntries.map(alertEntry => {
107
+ if (alertEntry.id !== id) {
108
+ return alertEntry;
109
+ }
110
+ return { ...alertEntry, height };
111
+ });
112
+ setAlertEntries(newAlertsState);
113
+ };
114
+
115
+ const removeEntry = (entryId: string) => {
116
+ setAlertEntries(entries => {
117
+ return entries.filter((entry, idx) => {
118
+ if (idx < stackSize) {
119
+ entries[idx] = { ...entries[idx], wasShown: true };
120
+ }
121
+ return entry.id !== entryId;
122
+ });
123
+ });
124
+ };
125
+
126
+ const renderAlertList = (): ReactNode => {
127
+ return alertEntries.slice(0, stackSize).map(entry => (
128
+ <AlertItem
129
+ {...entry}
130
+ key={`${entry.id}`}
131
+ onClose={() => {
132
+ removeEntry(entry.id);
133
+ entry.onClose?.();
134
+ }}
135
+ />
136
+ ));
137
+ };
138
+
139
+ const contextValue = useMemo(
140
+ () => ({
141
+ enqueueAlert,
142
+ enqueueInfoAlert,
143
+ enqueueSuccessAlert,
144
+ enqueueErrorAlert,
145
+ enqueueWarningAlert,
146
+ setAlertHeight,
147
+ alerts: alertEntries
148
+ }),
149
+ [
150
+ enqueueAlert,
151
+ enqueueInfoAlert,
152
+ enqueueSuccessAlert,
153
+ enqueueErrorAlert,
154
+ enqueueWarningAlert,
155
+ setAlertHeight,
156
+ alertEntries
157
+ ]
158
+ );
159
+
160
+ return (
161
+ <AlertContext.Provider value={contextValue}>
162
+ {children}
163
+ <div ref={wrappingDivRef}>
164
+ {createPortal(
165
+ <AlertContainer placement={placement} className={className}>
166
+ {renderAlertList()}
167
+ </AlertContainer>,
168
+ root
169
+ )}
170
+ </div>
171
+ </AlertContext.Provider>
172
+ );
173
+ };