@canonical/react-components 1.3.0 → 1.3.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 (348) hide show
  1. package/dist-esm/components/Accordion/Accordion.js +52 -0
  2. package/dist-esm/components/Accordion/AccordionSection/AccordionSection.js +47 -0
  3. package/dist-esm/components/Accordion/AccordionSection/index.js +1 -0
  4. package/dist-esm/components/Accordion/index.js +1 -0
  5. package/dist-esm/components/ActionButton/ActionButton.js +106 -0
  6. package/dist-esm/components/ActionButton/index.js +1 -0
  7. package/dist-esm/components/ApplicationLayout/AppAside/AppAside.js +29 -0
  8. package/dist-esm/components/ApplicationLayout/AppAside/index.js +1 -0
  9. package/dist-esm/components/ApplicationLayout/AppMain/AppMain.js +21 -0
  10. package/dist-esm/components/ApplicationLayout/AppMain/index.js +1 -0
  11. package/dist-esm/components/ApplicationLayout/AppNavigation/AppNavigation.js +31 -0
  12. package/dist-esm/components/ApplicationLayout/AppNavigation/index.js +1 -0
  13. package/dist-esm/components/ApplicationLayout/AppNavigationBar/AppNavigationBar.js +24 -0
  14. package/dist-esm/components/ApplicationLayout/AppNavigationBar/index.js +1 -0
  15. package/dist-esm/components/ApplicationLayout/AppStatus/AppStatus.js +21 -0
  16. package/dist-esm/components/ApplicationLayout/AppStatus/index.js +1 -0
  17. package/dist-esm/components/ApplicationLayout/Application/Application.js +22 -0
  18. package/dist-esm/components/ApplicationLayout/Application/index.js +1 -0
  19. package/dist-esm/components/ApplicationLayout/ApplicationLayout.js +113 -0
  20. package/dist-esm/components/ApplicationLayout/index.js +7 -0
  21. package/dist-esm/components/ArticlePagination/ArticlePagination.js +39 -0
  22. package/dist-esm/components/ArticlePagination/index.js +1 -0
  23. package/dist-esm/components/Badge/Badge.js +64 -0
  24. package/dist-esm/components/Badge/index.js +1 -0
  25. package/dist-esm/components/Button/Button.js +55 -0
  26. package/dist-esm/components/Button/index.js +1 -0
  27. package/dist-esm/components/Card/Card.js +45 -0
  28. package/dist-esm/components/Card/index.js +1 -0
  29. package/dist-esm/components/CheckboxInput/CheckableInput/CheckableInput.js +35 -0
  30. package/dist-esm/components/CheckboxInput/CheckableInput/index.js +1 -0
  31. package/dist-esm/components/CheckboxInput/CheckboxInput.js +24 -0
  32. package/dist-esm/components/CheckboxInput/index.js +1 -0
  33. package/dist-esm/components/Chip/Chip.js +81 -0
  34. package/dist-esm/components/Chip/index.js +1 -0
  35. package/dist-esm/components/Code/Code.js +49 -0
  36. package/dist-esm/components/Code/index.js +1 -0
  37. package/dist-esm/components/CodeSnippet/CodeSnippet.js +28 -0
  38. package/dist-esm/components/CodeSnippet/CodeSnippetBlock.js +64 -0
  39. package/dist-esm/components/CodeSnippet/CodeSnippetDropdown.js +27 -0
  40. package/dist-esm/components/CodeSnippet/index.js +2 -0
  41. package/dist-esm/components/Col/Col.js +38 -0
  42. package/dist-esm/components/Col/index.js +1 -0
  43. package/dist-esm/components/ConfirmationButton/ConfirmationButton.js +63 -0
  44. package/dist-esm/components/ConfirmationButton/index.js +1 -0
  45. package/dist-esm/components/ConfirmationModal/ConfirmationModal.js +47 -0
  46. package/dist-esm/components/ConfirmationModal/index.js +1 -0
  47. package/dist-esm/components/ContextualMenu/ContextualMenu.js +215 -0
  48. package/dist-esm/components/ContextualMenu/ContextualMenuDropdown/ContextualMenuDropdown.js +249 -0
  49. package/dist-esm/components/ContextualMenu/ContextualMenuDropdown/index.js +1 -0
  50. package/dist-esm/components/ContextualMenu/index.js +1 -0
  51. package/dist-esm/components/EmptyState/EmptyState.js +28 -0
  52. package/dist-esm/components/EmptyState/index.js +1 -0
  53. package/dist-esm/components/Field/Field.js +126 -0
  54. package/dist-esm/components/Field/index.js +1 -0
  55. package/dist-esm/components/Form/Form.js +28 -0
  56. package/dist-esm/components/Form/index.js +1 -0
  57. package/dist-esm/components/FormikField/FormikField.js +33 -0
  58. package/dist-esm/components/FormikField/index.js +1 -0
  59. package/dist-esm/components/Icon/Icon.js +61 -0
  60. package/dist-esm/components/Icon/index.js +1 -0
  61. package/dist-esm/components/Input/Input.js +103 -0
  62. package/dist-esm/components/Input/index.js +1 -0
  63. package/dist-esm/components/Label/Label.js +27 -0
  64. package/dist-esm/components/Label/index.js +1 -0
  65. package/dist-esm/components/Link/Link.js +37 -0
  66. package/dist-esm/components/Link/index.js +1 -0
  67. package/dist-esm/components/List/List.js +110 -0
  68. package/dist-esm/components/List/index.js +1 -0
  69. package/dist-esm/components/Loader/Loader.js +14 -0
  70. package/dist-esm/components/Loader/index.js +1 -0
  71. package/dist-esm/components/LoginPageLayout/LoginPageLayout.js +63 -0
  72. package/dist-esm/components/LoginPageLayout/index.js +1 -0
  73. package/dist-esm/components/MainTable/MainTable.js +211 -0
  74. package/dist-esm/components/MainTable/index.js +1 -0
  75. package/dist-esm/components/Modal/Modal.js +135 -0
  76. package/dist-esm/components/Modal/index.js +1 -0
  77. package/dist-esm/components/ModularTable/ModularTable.js +166 -0
  78. package/dist-esm/components/ModularTable/index.js +1 -0
  79. package/dist-esm/components/MultiSelect/FadeInDown/FadeInDown.js +25 -0
  80. package/dist-esm/components/MultiSelect/FadeInDown/index.js +1 -0
  81. package/dist-esm/components/MultiSelect/MultiSelect.js +308 -0
  82. package/dist-esm/components/MultiSelect/index.js +1 -0
  83. package/dist-esm/components/Navigation/Navigation.js +215 -0
  84. package/dist-esm/components/Navigation/NavigationLink/NavigationLink.js +58 -0
  85. package/dist-esm/components/Navigation/NavigationLink/index.js +1 -0
  86. package/dist-esm/components/Navigation/NavigationMenu/NavigationMenu.js +57 -0
  87. package/dist-esm/components/Navigation/NavigationMenu/index.js +1 -0
  88. package/dist-esm/components/Navigation/index.js +1 -0
  89. package/dist-esm/components/Navigation/types.js +1 -0
  90. package/dist-esm/components/Notification/Notification.js +119 -0
  91. package/dist-esm/components/Notification/index.js +1 -0
  92. package/dist-esm/components/NotificationProvider/NotificationProvider.js +83 -0
  93. package/dist-esm/components/NotificationProvider/index.js +2 -0
  94. package/dist-esm/components/NotificationProvider/messageBuilder.js +31 -0
  95. package/dist-esm/components/NotificationProvider/types.js +1 -0
  96. package/dist-esm/components/Pagination/Pagination.js +173 -0
  97. package/dist-esm/components/Pagination/PaginationButton/PaginationButton.js +31 -0
  98. package/dist-esm/components/Pagination/PaginationButton/index.js +1 -0
  99. package/dist-esm/components/Pagination/PaginationItem/PaginationItem.js +20 -0
  100. package/dist-esm/components/Pagination/PaginationItem/index.js +1 -0
  101. package/dist-esm/components/Pagination/index.js +1 -0
  102. package/dist-esm/components/Panel/Panel.js +89 -0
  103. package/dist-esm/components/Panel/index.js +1 -0
  104. package/dist-esm/components/PasswordToggle/PasswordToggle.js +90 -0
  105. package/dist-esm/components/PasswordToggle/index.js +1 -0
  106. package/dist-esm/components/RadioInput/RadioInput.js +22 -0
  107. package/dist-esm/components/RadioInput/index.js +1 -0
  108. package/dist-esm/components/Row/Row.js +22 -0
  109. package/dist-esm/components/Row/index.js +1 -0
  110. package/dist-esm/components/SearchAndFilter/FilterPanelSection/FilterPanelSection.js +107 -0
  111. package/dist-esm/components/SearchAndFilter/FilterPanelSection/index.js +1 -0
  112. package/dist-esm/components/SearchAndFilter/SearchAndFilter.js +286 -0
  113. package/dist-esm/components/SearchAndFilter/index.js +1 -0
  114. package/dist-esm/components/SearchAndFilter/types.js +1 -0
  115. package/dist-esm/components/SearchAndFilter/utils.js +22 -0
  116. package/dist-esm/components/SearchBox/SearchBox.js +95 -0
  117. package/dist-esm/components/SearchBox/index.js +1 -0
  118. package/dist-esm/components/Select/Select.js +84 -0
  119. package/dist-esm/components/Select/index.js +1 -0
  120. package/dist-esm/components/SideNavigation/SideNavigation.js +89 -0
  121. package/dist-esm/components/SideNavigation/SideNavigationBase/SideNavigationBase.js +31 -0
  122. package/dist-esm/components/SideNavigation/SideNavigationBase/index.js +1 -0
  123. package/dist-esm/components/SideNavigation/SideNavigationItem/SideNavigationItem.js +32 -0
  124. package/dist-esm/components/SideNavigation/SideNavigationItem/index.js +1 -0
  125. package/dist-esm/components/SideNavigation/SideNavigationLink/SideNavigationLink.js +25 -0
  126. package/dist-esm/components/SideNavigation/SideNavigationLink/index.js +1 -0
  127. package/dist-esm/components/SideNavigation/SideNavigationText/SideNavigationText.js +20 -0
  128. package/dist-esm/components/SideNavigation/SideNavigationText/index.js +1 -0
  129. package/dist-esm/components/SideNavigation/index.js +4 -0
  130. package/dist-esm/components/Slider/Slider.js +83 -0
  131. package/dist-esm/components/Slider/index.js +1 -0
  132. package/dist-esm/components/Spinner/Spinner.js +36 -0
  133. package/dist-esm/components/Spinner/index.js +1 -0
  134. package/dist-esm/components/StatusLabel/StatusLabel.js +36 -0
  135. package/dist-esm/components/StatusLabel/index.js +1 -0
  136. package/dist-esm/components/Strip/Strip.js +50 -0
  137. package/dist-esm/components/Strip/index.js +1 -0
  138. package/dist-esm/components/SummaryButton/SummaryButton.js +28 -0
  139. package/dist-esm/components/SummaryButton/index.js +1 -0
  140. package/dist-esm/components/Switch/Switch.js +28 -0
  141. package/dist-esm/components/Switch/index.js +1 -0
  142. package/dist-esm/components/Table/Table.js +23 -0
  143. package/dist-esm/components/Table/index.js +1 -0
  144. package/dist-esm/components/TableCell/TableCell.js +26 -0
  145. package/dist-esm/components/TableCell/index.js +1 -0
  146. package/dist-esm/components/TableHeader/TableHeader.js +17 -0
  147. package/dist-esm/components/TableHeader/index.js +1 -0
  148. package/dist-esm/components/TablePagination/TablePagination.js +104 -0
  149. package/dist-esm/components/TablePagination/TablePaginationControls/TablePaginationControls.js +120 -0
  150. package/dist-esm/components/TablePagination/TablePaginationControls/index.js +1 -0
  151. package/dist-esm/components/TablePagination/index.js +1 -0
  152. package/dist-esm/components/TablePagination/utils.js +67 -0
  153. package/dist-esm/components/TableRow/TableRow.js +15 -0
  154. package/dist-esm/components/TableRow/index.js +1 -0
  155. package/dist-esm/components/Tabs/Tabs.js +42 -0
  156. package/dist-esm/components/Tabs/index.js +1 -0
  157. package/dist-esm/components/Textarea/Textarea.js +115 -0
  158. package/dist-esm/components/Textarea/index.js +1 -0
  159. package/dist-esm/components/Tooltip/Tooltip.js +245 -0
  160. package/dist-esm/components/Tooltip/index.js +1 -0
  161. package/dist-esm/enums.js +8 -0
  162. package/dist-esm/hooks/index.js +8 -0
  163. package/dist-esm/hooks/useId.js +13 -0
  164. package/dist-esm/hooks/useListener.js +51 -0
  165. package/dist-esm/hooks/useOnClickOutside.js +38 -0
  166. package/dist-esm/hooks/useOnEscapePressed.js +25 -0
  167. package/dist-esm/hooks/usePagination.js +45 -0
  168. package/dist-esm/hooks/usePrevious.js +16 -0
  169. package/dist-esm/hooks/useThrottle.js +49 -0
  170. package/dist-esm/hooks/useWindowFitment.js +109 -0
  171. package/dist-esm/index.js +69 -0
  172. package/dist-esm/types/index.js +1 -0
  173. package/dist-esm/types/react-table-config.d.js +1 -0
  174. package/dist-esm/utils.js +41 -0
  175. package/dist-types/components/Accordion/Accordion.d.ts +46 -0
  176. package/dist-types/components/Accordion/AccordionSection/AccordionSection.d.ts +34 -0
  177. package/dist-types/components/Accordion/AccordionSection/index.d.ts +2 -0
  178. package/dist-types/components/Accordion/index.d.ts +2 -0
  179. package/dist-types/components/ActionButton/ActionButton.d.ts +48 -0
  180. package/dist-types/components/ActionButton/index.d.ts +2 -0
  181. package/dist-types/components/ApplicationLayout/AppAside/AppAside.d.ts +33 -0
  182. package/dist-types/components/ApplicationLayout/AppAside/index.d.ts +2 -0
  183. package/dist-types/components/ApplicationLayout/AppMain/AppMain.d.ts +14 -0
  184. package/dist-types/components/ApplicationLayout/AppMain/index.d.ts +2 -0
  185. package/dist-types/components/ApplicationLayout/AppNavigation/AppNavigation.d.ts +26 -0
  186. package/dist-types/components/ApplicationLayout/AppNavigation/index.d.ts +2 -0
  187. package/dist-types/components/ApplicationLayout/AppNavigationBar/AppNavigationBar.d.ts +18 -0
  188. package/dist-types/components/ApplicationLayout/AppNavigationBar/index.d.ts +2 -0
  189. package/dist-types/components/ApplicationLayout/AppStatus/AppStatus.d.ts +14 -0
  190. package/dist-types/components/ApplicationLayout/AppStatus/index.d.ts +2 -0
  191. package/dist-types/components/ApplicationLayout/Application/Application.d.ts +15 -0
  192. package/dist-types/components/ApplicationLayout/Application/index.d.ts +2 -0
  193. package/dist-types/components/ApplicationLayout/ApplicationLayout.d.ts +89 -0
  194. package/dist-types/components/ApplicationLayout/index.d.ts +7 -0
  195. package/dist-types/components/ArticlePagination/ArticlePagination.d.ts +31 -0
  196. package/dist-types/components/ArticlePagination/index.d.ts +2 -0
  197. package/dist-types/components/Badge/Badge.d.ts +34 -0
  198. package/dist-types/components/Badge/index.d.ts +2 -0
  199. package/dist-types/components/Button/Button.d.ts +64 -0
  200. package/dist-types/components/Button/index.d.ts +2 -0
  201. package/dist-types/components/Card/Card.d.ts +35 -0
  202. package/dist-types/components/Card/index.d.ts +2 -0
  203. package/dist-types/components/CheckboxInput/CheckableInput/CheckableInput.d.ts +27 -0
  204. package/dist-types/components/CheckboxInput/CheckableInput/index.d.ts +2 -0
  205. package/dist-types/components/CheckboxInput/CheckboxInput.d.ts +9 -0
  206. package/dist-types/components/CheckboxInput/index.d.ts +2 -0
  207. package/dist-types/components/Chip/Chip.d.ts +56 -0
  208. package/dist-types/components/Chip/index.d.ts +2 -0
  209. package/dist-types/components/Code/Code.d.ts +13 -0
  210. package/dist-types/components/Code/index.d.ts +2 -0
  211. package/dist-types/components/CodeSnippet/CodeSnippet.d.ts +21 -0
  212. package/dist-types/components/CodeSnippet/CodeSnippetBlock.d.ts +40 -0
  213. package/dist-types/components/CodeSnippet/CodeSnippetDropdown.d.ts +18 -0
  214. package/dist-types/components/CodeSnippet/index.d.ts +5 -0
  215. package/dist-types/components/Col/Col.d.ts +53 -0
  216. package/dist-types/components/Col/index.d.ts +2 -0
  217. package/dist-types/components/ConfirmationButton/ConfirmationButton.d.ts +28 -0
  218. package/dist-types/components/ConfirmationButton/index.d.ts +2 -0
  219. package/dist-types/components/ConfirmationModal/ConfirmationModal.d.ts +53 -0
  220. package/dist-types/components/ConfirmationModal/index.d.ts +2 -0
  221. package/dist-types/components/ContextualMenu/ContextualMenu.d.ts +110 -0
  222. package/dist-types/components/ContextualMenu/ContextualMenuDropdown/ContextualMenuDropdown.d.ts +43 -0
  223. package/dist-types/components/ContextualMenu/ContextualMenuDropdown/index.d.ts +2 -0
  224. package/dist-types/components/ContextualMenu/index.d.ts +3 -0
  225. package/dist-types/components/EmptyState/EmptyState.d.ts +25 -0
  226. package/dist-types/components/EmptyState/index.d.ts +2 -0
  227. package/dist-types/components/Field/Field.d.ts +77 -0
  228. package/dist-types/components/Field/index.d.ts +2 -0
  229. package/dist-types/components/Form/Form.d.ts +21 -0
  230. package/dist-types/components/Form/index.d.ts +2 -0
  231. package/dist-types/components/FormikField/FormikField.d.ts +25 -0
  232. package/dist-types/components/FormikField/index.d.ts +1 -0
  233. package/dist-types/components/Icon/Icon.d.ts +59 -0
  234. package/dist-types/components/Icon/index.d.ts +2 -0
  235. package/dist-types/components/Input/Input.d.ts +70 -0
  236. package/dist-types/components/Input/index.d.ts +2 -0
  237. package/dist-types/components/Label/Label.d.ts +25 -0
  238. package/dist-types/components/Label/index.d.ts +2 -0
  239. package/dist-types/components/Link/Link.d.ts +31 -0
  240. package/dist-types/components/Link/index.d.ts +2 -0
  241. package/dist-types/components/List/List.d.ts +36 -0
  242. package/dist-types/components/List/index.d.ts +2 -0
  243. package/dist-types/components/Loader/Loader.d.ts +6 -0
  244. package/dist-types/components/Loader/index.d.ts +1 -0
  245. package/dist-types/components/LoginPageLayout/LoginPageLayout.d.ts +17 -0
  246. package/dist-types/components/LoginPageLayout/index.d.ts +2 -0
  247. package/dist-types/components/MainTable/MainTable.d.ts +102 -0
  248. package/dist-types/components/MainTable/index.d.ts +2 -0
  249. package/dist-types/components/Modal/Modal.d.ts +36 -0
  250. package/dist-types/components/Modal/index.d.ts +2 -0
  251. package/dist-types/components/ModularTable/ModularTable.d.ts +105 -0
  252. package/dist-types/components/ModularTable/index.d.ts +2 -0
  253. package/dist-types/components/MultiSelect/FadeInDown/FadeInDown.d.ts +10 -0
  254. package/dist-types/components/MultiSelect/FadeInDown/index.d.ts +1 -0
  255. package/dist-types/components/MultiSelect/MultiSelect.d.ts +57 -0
  256. package/dist-types/components/MultiSelect/index.d.ts +1 -0
  257. package/dist-types/components/Navigation/Navigation.d.ts +66 -0
  258. package/dist-types/components/Navigation/NavigationLink/NavigationLink.d.ts +10 -0
  259. package/dist-types/components/Navigation/NavigationLink/index.d.ts +1 -0
  260. package/dist-types/components/Navigation/NavigationMenu/NavigationMenu.d.ts +11 -0
  261. package/dist-types/components/Navigation/NavigationMenu/index.d.ts +1 -0
  262. package/dist-types/components/Navigation/index.d.ts +3 -0
  263. package/dist-types/components/Navigation/types.d.ts +64 -0
  264. package/dist-types/components/Notification/Notification.d.ts +110 -0
  265. package/dist-types/components/Notification/index.d.ts +2 -0
  266. package/dist-types/components/NotificationProvider/NotificationProvider.d.ts +5 -0
  267. package/dist-types/components/NotificationProvider/index.d.ts +3 -0
  268. package/dist-types/components/NotificationProvider/messageBuilder.d.ts +6 -0
  269. package/dist-types/components/NotificationProvider/types.d.ts +35 -0
  270. package/dist-types/components/Pagination/Pagination.d.ts +102 -0
  271. package/dist-types/components/Pagination/PaginationButton/PaginationButton.d.ts +30 -0
  272. package/dist-types/components/Pagination/PaginationButton/index.d.ts +2 -0
  273. package/dist-types/components/Pagination/PaginationItem/PaginationItem.d.ts +17 -0
  274. package/dist-types/components/Pagination/PaginationItem/index.d.ts +2 -0
  275. package/dist-types/components/Pagination/index.d.ts +2 -0
  276. package/dist-types/components/Panel/Panel.d.ts +123 -0
  277. package/dist-types/components/Panel/index.d.ts +1 -0
  278. package/dist-types/components/PasswordToggle/PasswordToggle.d.ts +108 -0
  279. package/dist-types/components/PasswordToggle/index.d.ts +2 -0
  280. package/dist-types/components/RadioInput/RadioInput.d.ts +9 -0
  281. package/dist-types/components/RadioInput/index.d.ts +2 -0
  282. package/dist-types/components/Row/Row.d.ts +19 -0
  283. package/dist-types/components/Row/index.d.ts +2 -0
  284. package/dist-types/components/SearchAndFilter/FilterPanelSection/FilterPanelSection.d.ts +25 -0
  285. package/dist-types/components/SearchAndFilter/FilterPanelSection/index.d.ts +1 -0
  286. package/dist-types/components/SearchAndFilter/SearchAndFilter.d.ts +33 -0
  287. package/dist-types/components/SearchAndFilter/index.d.ts +2 -0
  288. package/dist-types/components/SearchAndFilter/types.d.ts +11 -0
  289. package/dist-types/components/SearchAndFilter/utils.d.ts +13 -0
  290. package/dist-types/components/SearchBox/SearchBox.d.ts +63 -0
  291. package/dist-types/components/SearchBox/index.d.ts +2 -0
  292. package/dist-types/components/Select/Select.d.ts +71 -0
  293. package/dist-types/components/Select/index.d.ts +2 -0
  294. package/dist-types/components/SideNavigation/SideNavigation.d.ts +50 -0
  295. package/dist-types/components/SideNavigation/SideNavigationBase/SideNavigationBase.d.ts +31 -0
  296. package/dist-types/components/SideNavigation/SideNavigationBase/index.d.ts +1 -0
  297. package/dist-types/components/SideNavigation/SideNavigationItem/SideNavigationItem.d.ts +20 -0
  298. package/dist-types/components/SideNavigation/SideNavigationItem/index.d.ts +1 -0
  299. package/dist-types/components/SideNavigation/SideNavigationLink/SideNavigationLink.d.ts +18 -0
  300. package/dist-types/components/SideNavigation/SideNavigationLink/index.d.ts +1 -0
  301. package/dist-types/components/SideNavigation/SideNavigationText/SideNavigationText.d.ts +7 -0
  302. package/dist-types/components/SideNavigation/SideNavigationText/index.d.ts +1 -0
  303. package/dist-types/components/SideNavigation/index.d.ts +5 -0
  304. package/dist-types/components/Slider/Slider.d.ts +62 -0
  305. package/dist-types/components/Slider/index.d.ts +2 -0
  306. package/dist-types/components/Spinner/Spinner.d.ts +29 -0
  307. package/dist-types/components/Spinner/index.d.ts +2 -0
  308. package/dist-types/components/StatusLabel/StatusLabel.d.ts +33 -0
  309. package/dist-types/components/StatusLabel/index.d.ts +2 -0
  310. package/dist-types/components/Strip/Strip.d.ts +64 -0
  311. package/dist-types/components/Strip/index.d.ts +2 -0
  312. package/dist-types/components/SummaryButton/SummaryButton.d.ts +29 -0
  313. package/dist-types/components/SummaryButton/index.d.ts +2 -0
  314. package/dist-types/components/Switch/Switch.d.ts +17 -0
  315. package/dist-types/components/Switch/index.d.ts +2 -0
  316. package/dist-types/components/Table/Table.d.ts +22 -0
  317. package/dist-types/components/Table/index.d.ts +2 -0
  318. package/dist-types/components/TableCell/TableCell.d.ts +26 -0
  319. package/dist-types/components/TableCell/index.d.ts +2 -0
  320. package/dist-types/components/TableHeader/TableHeader.d.ts +14 -0
  321. package/dist-types/components/TableHeader/index.d.ts +2 -0
  322. package/dist-types/components/TablePagination/TablePagination.d.ts +98 -0
  323. package/dist-types/components/TablePagination/TablePaginationControls/TablePaginationControls.d.ts +24 -0
  324. package/dist-types/components/TablePagination/TablePaginationControls/index.d.ts +2 -0
  325. package/dist-types/components/TablePagination/index.d.ts +2 -0
  326. package/dist-types/components/TablePagination/utils.d.ts +27 -0
  327. package/dist-types/components/TableRow/TableRow.d.ts +10 -0
  328. package/dist-types/components/TableRow/index.d.ts +2 -0
  329. package/dist-types/components/Tabs/Tabs.d.ts +45 -0
  330. package/dist-types/components/Tabs/index.d.ts +2 -0
  331. package/dist-types/components/Textarea/Textarea.d.ts +70 -0
  332. package/dist-types/components/Textarea/index.d.ts +2 -0
  333. package/dist-types/components/Tooltip/Tooltip.d.ts +75 -0
  334. package/dist-types/components/Tooltip/index.d.ts +2 -0
  335. package/dist-types/enums.d.ts +13 -0
  336. package/dist-types/hooks/index.d.ts +9 -0
  337. package/dist-types/hooks/useId.d.ts +4 -0
  338. package/dist-types/hooks/useListener.d.ts +11 -0
  339. package/dist-types/hooks/useOnClickOutside.d.ts +12 -0
  340. package/dist-types/hooks/useOnEscapePressed.d.ts +6 -0
  341. package/dist-types/hooks/usePagination.d.ts +19 -0
  342. package/dist-types/hooks/usePrevious.d.ts +7 -0
  343. package/dist-types/hooks/useThrottle.d.ts +9 -0
  344. package/dist-types/hooks/useWindowFitment.d.ts +54 -0
  345. package/dist-types/index.d.ts +132 -0
  346. package/dist-types/types/index.d.ts +38 -0
  347. package/dist-types/utils.d.ts +27 -0
  348. package/package.json +3 -1
@@ -0,0 +1,62 @@
1
+ import type { ChangeEventHandler, HTMLProps, ReactNode } from "react";
2
+ import type { PropsWithSpread } from "../../types";
3
+ export declare const FILLED_COLOR = "#0066CC";
4
+ export declare const EMPTY_COLOR = "#D9D9D9";
5
+ export type Props = PropsWithSpread<{
6
+ /**
7
+ * Field caution message.
8
+ */
9
+ caution?: ReactNode;
10
+ /**
11
+ * Whether to disable the slider and input (if showInput is true).
12
+ */
13
+ disabled?: boolean;
14
+ /**
15
+ * Field error message.
16
+ */
17
+ error?: ReactNode;
18
+ /**
19
+ * Field help message.
20
+ */
21
+ help?: ReactNode;
22
+ /**
23
+ * Field id. Only passed to range input, not to number input.
24
+ */
25
+ id?: string;
26
+ /**
27
+ * Whether to disable only the input, but not the slider.
28
+ */
29
+ inputDisabled?: boolean;
30
+ /**
31
+ * Field label.
32
+ */
33
+ label?: ReactNode;
34
+ /**
35
+ * Maximum value of the slider.
36
+ */
37
+ max: number;
38
+ /**
39
+ * Minimum value of the slider.
40
+ */
41
+ min: number;
42
+ /**
43
+ * Change event handler.
44
+ */
45
+ onChange: ChangeEventHandler<HTMLInputElement>;
46
+ /**
47
+ * Whether the field is required for the form to submit.
48
+ */
49
+ required?: boolean;
50
+ /**
51
+ * Whether to show a number input with the numerical value next to the slider.
52
+ */
53
+ showInput?: boolean;
54
+ }, HTMLProps<HTMLInputElement>>;
55
+ /**
56
+ * This is the [React](https://reactjs.org/) component for the Vanilla [Slider](https://vanillaframework.io/docs/patterns/slider).
57
+ *
58
+ * Sliders should be used to let a user specify a numeric value between a defined
59
+ minimum and maximum value, however the precise value is not especially important.
60
+ */
61
+ export declare const Slider: ({ caution, disabled, error, help, id, inputDisabled, label, max, min, onChange, required, showInput, ...inputProps }: Props) => JSX.Element;
62
+ export default Slider;
@@ -0,0 +1,2 @@
1
+ export { default } from "./Slider";
2
+ export type { Props as SliderProps } from "./Slider";
@@ -0,0 +1,29 @@
1
+ import { HTMLProps } from "react";
2
+ import type { ClassName } from "../../types";
3
+ export type Props = {
4
+ /**
5
+ * Optional class(es) to pass to the wrapping span element.
6
+ */
7
+ className?: ClassName;
8
+ /**
9
+ * Whether the spinner should have a light appearance.
10
+ */
11
+ isLight?: boolean;
12
+ /**
13
+ * Text to display next to the spinner.
14
+ */
15
+ text?: string;
16
+ /**
17
+ * What the role of the spinner should be.
18
+ */
19
+ role?: string;
20
+ /**
21
+ * The politeness setting of the spinner alert.
22
+ */
23
+ ariaLive?: "assertive" | "off" | "polite";
24
+ } & HTMLProps<HTMLSpanElement>;
25
+ /**
26
+ * This is a [React](https://reactjs.org/) component for the Vanilla [Spin](https://docs.vanillaframework.io/settings/animation-settings/#spin) animation.
27
+ */
28
+ declare const Spinner: ({ className, text, isLight, ariaLive, role, ...props }: Props) => JSX.Element;
29
+ export default Spinner;
@@ -0,0 +1,2 @@
1
+ export { default } from "./Spinner";
2
+ export type { Props as SpinnerProps } from "./Spinner";
@@ -0,0 +1,33 @@
1
+ import type { HTMLProps, ReactNode } from "react";
2
+ import { ClassName, PropsWithSpread, ValueOf } from "../../types";
3
+ export declare const StatusLabelAppearance: {
4
+ readonly CAUTION: "caution";
5
+ readonly DEFAULT: "";
6
+ readonly INFORMATION: "information";
7
+ readonly NEGATIVE: "negative";
8
+ readonly POSITIVE: "positive";
9
+ };
10
+ /**
11
+ * The type of the StatusLabel props.
12
+ */
13
+ export type Props = PropsWithSpread<{
14
+ /**
15
+ * The appearance of the label.
16
+ */
17
+ appearance?: ValueOf<typeof StatusLabelAppearance> | string;
18
+ /**
19
+ * The content of the label.
20
+ */
21
+ children?: ReactNode;
22
+ /**
23
+ * Optional class(es) to pass to the wrapping element.
24
+ */
25
+ className?: ClassName;
26
+ }, HTMLProps<HTMLDivElement>>;
27
+ /**
28
+ * This is a [React](https://reactjs.org/) component for the Vanilla [Label](https://vanillaframework.io/docs/patterns/labels).
29
+ *
30
+ * Labels are static elements which you can apply to signify status, tags or any other information you find useful.
31
+ */
32
+ declare const StatusLabel: ({ appearance, children, className, ...labelProps }: Props) => JSX.Element;
33
+ export default StatusLabel;
@@ -0,0 +1,2 @@
1
+ export { default, StatusLabelAppearance } from "./StatusLabel";
2
+ export type { Props as StatusLabelProps } from "./StatusLabel";
@@ -0,0 +1,64 @@
1
+ import type { ElementType, HTMLProps, ReactNode } from "react";
2
+ import type { ColSize } from "../Col/Col";
3
+ import type { ClassName, PropsWithSpread } from "../../types";
4
+ export type Props = PropsWithSpread<{
5
+ /**
6
+ * The content of the strip.
7
+ */
8
+ children: ReactNode;
9
+ /**
10
+ * A background images for the strip.
11
+ */
12
+ background?: string;
13
+ /**
14
+ * Whether the strip should display borders.
15
+ */
16
+ bordered?: boolean;
17
+ /**
18
+ * Optional classes for the strip.
19
+ */
20
+ className?: ClassName;
21
+ /**
22
+ * The width of the column if `includeCol` has been set.
23
+ */
24
+ colSize?: ColSize;
25
+ /**
26
+ * Whether the strip should be dark.
27
+ */
28
+ dark?: boolean;
29
+ /**
30
+ * Whether the strip should be deep.
31
+ */
32
+ deep?: boolean;
33
+ /**
34
+ * The base HTML element of the strip.
35
+ */
36
+ element?: ElementType;
37
+ /**
38
+ * Whether the strip should wrap the content in a column.
39
+ */
40
+ includeCol?: boolean;
41
+ /**
42
+ * Whether the strip should be light.
43
+ */
44
+ light?: boolean;
45
+ /**
46
+ * Optional classes to apply to the row.
47
+ */
48
+ rowClassName?: string;
49
+ /**
50
+ * Whether the strip should be shallow.
51
+ */
52
+ shallow?: boolean;
53
+ /**
54
+ * The type of the strip (e.g. "accent" or "image").
55
+ */
56
+ type?: string;
57
+ }, HTMLProps<HTMLElement>>;
58
+ /**
59
+ * This is a [React](https://reactjs.org/) component for the Vanilla [Strip](https://docs.vanillaframework.io/patterns/strip/).
60
+ *
61
+ * The strip pattern provides a full width strip container in which to wrap a row.
62
+ */
63
+ declare const Strip: ({ background, bordered, children, className, colSize, dark, deep, includeCol, element: Component, light, rowClassName, shallow, type, ...props }: Props) => JSX.Element;
64
+ export default Strip;
@@ -0,0 +1,2 @@
1
+ export { default } from "./Strip";
2
+ export type { Props as StripProps } from "./Strip";
@@ -0,0 +1,29 @@
1
+ import type { MouseEventHandler } from "react";
2
+ import type { ClassName } from "../../types";
3
+ export type Props = {
4
+ /**
5
+ * Optional class(es) to pass to the wrapping element.
6
+ */
7
+ className?: ClassName;
8
+ /**
9
+ * Whether the summary button is loading.
10
+ */
11
+ isLoading?: boolean;
12
+ /**
13
+ * The label of the summary button.
14
+ */
15
+ label: string;
16
+ /**
17
+ * Function to handle clicking the summary button.
18
+ */
19
+ onClick: MouseEventHandler<HTMLButtonElement>;
20
+ /**
21
+ * The summary content.
22
+ */
23
+ summary?: string;
24
+ };
25
+ /**
26
+ * `SummaryButton` is a component to render a short summary with an action button. It's initial use case is a summary of table contents with action to load more items.
27
+ */
28
+ declare const SummaryButton: ({ className, isLoading, summary, label, onClick, }: Props) => JSX.Element;
29
+ export default SummaryButton;
@@ -0,0 +1,2 @@
1
+ export { default } from "./SummaryButton";
2
+ export type { Props as SummaryButtonProps } from "./SummaryButton";
@@ -0,0 +1,17 @@
1
+ import type { HTMLProps, ReactNode } from "react";
2
+ import type { PropsWithSpread } from "../../types";
3
+ export type Props = PropsWithSpread<{
4
+ /**
5
+ * The label name for the switch
6
+ */
7
+ label: ReactNode;
8
+ /**
9
+ * Whether the switch is disabled or not
10
+ */
11
+ disabled?: boolean;
12
+ }, HTMLProps<HTMLInputElement>>;
13
+ /**
14
+ * This is a [React](https://reactjs.org/) component for the Vanilla [Switch](https://vanillaframework.io/docs/patterns/switch) component.
15
+ */
16
+ export declare const Switch: ({ label, disabled, ...inputProps }: Props) => JSX.Element;
17
+ export default Switch;
@@ -0,0 +1,2 @@
1
+ export { default } from "./Switch";
2
+ export type { Props as SwitchProps } from "./Switch";
@@ -0,0 +1,22 @@
1
+ import { HTMLProps, ReactNode } from "react";
2
+ import type { ClassName, PropsWithSpread } from "../../types";
3
+ export type Props = PropsWithSpread<{
4
+ /**
5
+ * The content of the table.
6
+ */
7
+ children?: ReactNode;
8
+ /**
9
+ * Optional class(es) to pass to the wrapping table element.
10
+ */
11
+ className?: ClassName;
12
+ /**
13
+ * Whether the table can expand hidden cells.
14
+ */
15
+ expanding?: boolean;
16
+ /**
17
+ * Whether the table should show card styling on smaller screens.
18
+ */
19
+ responsive?: boolean;
20
+ }, HTMLProps<HTMLTableElement>>;
21
+ declare const Table: ({ children, className, expanding, responsive, ...props }: Props) => JSX.Element;
22
+ export default Table;
@@ -0,0 +1,2 @@
1
+ export { default } from "./Table";
2
+ export type { Props as TableProps } from "./Table";
@@ -0,0 +1,26 @@
1
+ import { HTMLProps, ReactNode } from "react";
2
+ import type { ClassName, PropsWithSpread } from "../../types";
3
+ export type Props = PropsWithSpread<{
4
+ /**
5
+ * The content of the table cell.
6
+ */
7
+ children?: ReactNode;
8
+ /**
9
+ * Optional class(es) to pass to the wrapping td element.
10
+ */
11
+ className?: ClassName;
12
+ /**
13
+ * Whether the cell is an expanded cell.
14
+ */
15
+ expanding?: boolean;
16
+ /**
17
+ * Whether content of the cell should be able to overflow, e.g. a dropdown.
18
+ */
19
+ hasOverflow?: boolean;
20
+ /**
21
+ * Whether the cell is currently hidden.
22
+ */
23
+ hidden?: boolean;
24
+ }, HTMLProps<HTMLTableCellElement>>;
25
+ declare const TableCell: ({ children, className, hasOverflow, expanding, hidden, role, ...props }: Props) => JSX.Element;
26
+ export default TableCell;
@@ -0,0 +1,2 @@
1
+ export { default } from "./TableCell";
2
+ export type { Props as TableCellProps } from "./TableCell";
@@ -0,0 +1,14 @@
1
+ import { HTMLProps, ReactNode } from "react";
2
+ import { PropsWithSpread, SortDirection } from "../../types";
3
+ export type Props = PropsWithSpread<{
4
+ /**
5
+ * The content of the table header.
6
+ */
7
+ children?: ReactNode;
8
+ /**
9
+ * The direction of sorting, if applicable.
10
+ */
11
+ sort?: SortDirection;
12
+ }, HTMLProps<HTMLTableHeaderCellElement>>;
13
+ declare const TableHeader: ({ children, sort, ...props }: Props) => JSX.Element;
14
+ export default TableHeader;
@@ -0,0 +1,2 @@
1
+ export { default } from "./TableHeader";
2
+ export type { Props as TableHeaderProps } from "./TableHeader";
@@ -0,0 +1,98 @@
1
+ import React, { HTMLAttributes, PropsWithChildren, ReactNode } from "react";
2
+ import "./TablePagination.scss";
3
+ export type BasePaginationProps = {
4
+ /**
5
+ * list of data elements to be paginated. This component is un-opinionated about
6
+ * the structure of the data but it should be identical to the data structure
7
+ * required by the child table component
8
+ */
9
+ data: unknown[];
10
+ /**
11
+ * prop name of the child table component that receives paginated data.
12
+ * default value is set to `rows`, which is the data prop for the `MainTable` component
13
+ */
14
+ dataForwardProp?: string;
15
+ /**
16
+ * the name of the item associated to each row within the table.
17
+ */
18
+ itemName?: string;
19
+ /**
20
+ * custom styling for the pagination container
21
+ */
22
+ className?: string;
23
+ /**
24
+ * custom description to be displayed by the pagination
25
+ */
26
+ description?: ReactNode;
27
+ /**
28
+ * custom per page limits express as an array of numbers.
29
+ */
30
+ pageLimits?: number[];
31
+ /**
32
+ * place the pagination component above or below the table?
33
+ */
34
+ position?: "above" | "below";
35
+ };
36
+ export type ExternalControlProps = BasePaginationProps & {
37
+ /**
38
+ * Whether the component will be controlled via external state.
39
+ */
40
+ externallyControlled?: true;
41
+ /**
42
+ * the total number of items available within the data. This prop is only relevant
43
+ * and will be required if `externallyControlled` is set to `true`.
44
+ */
45
+ totalItems: number;
46
+ /**
47
+ * the current page that's showing. This prop is only relevant and will be required
48
+ * if `externallyControlled` is set to `true`.
49
+ */
50
+ currentPage: number;
51
+ /**
52
+ * size per page. This prop is only relevant and will be required if
53
+ * `externallyControlled` is set to `true`.
54
+ */
55
+ pageSize: number;
56
+ /**
57
+ * callback indicating a page change event to the parent component.
58
+ * This prop is only relevant and will be required if `externallyControlled` is set
59
+ * to `true`.
60
+ */
61
+ onPageChange: (page: number) => void;
62
+ /**
63
+ * callback indicating a page size change event to the parent component.
64
+ * This prop is only relevant and will be required if `externallyControlled` is set
65
+ * to `true`.
66
+ */
67
+ onPageSizeChange: (pageSize: number) => void;
68
+ };
69
+ export type InternalControlProps = BasePaginationProps & {
70
+ /**
71
+ * Whether the component will be controlled via external state.
72
+ */
73
+ externallyControlled?: false;
74
+ };
75
+ export type Props = PropsWithChildren<ExternalControlProps | InternalControlProps> & HTMLAttributes<HTMLDivElement>;
76
+ /**
77
+ This is an HOC [React](https://reactjs.org/) component for applying pagination to direct children components. This component is un-opinionated about
78
+ the structure of the input data and can be used with any child component that displays a list of data. However, the styling and behaviour of this component were designed
79
+ to work nicely with the `MainTable` component. To use this component, simply wrap a child component with it and provide the data that you want
80
+ to paginate to the `data` prop. This component will then pass the paged data to all <b>direct</b> child components via a child prop specified by `dataForwardProp`.
81
+ The component may be externally controlled, see following sections for detailed explanation.
82
+
83
+ #### Externally controlled pagination
84
+
85
+ For externally controlled mode, you will be responsible for the pagination logic and therefore the component will be purely presentational.
86
+ The pagination behaviour is controlled outside of this component. Note the data injection to child components is essentially a passthrough in this case.
87
+ To enable externally controlled mode for this component, set the `externallyControlled` prop to `true`. From there, it is your responsibility
88
+ to ensure that the following props `totalItems`, `currentPage`, `pageSize`, `onPageChange` and `onPageSizeChange` are set properly.
89
+ You can refer to the props table below on how to set these props.
90
+
91
+ #### Un-controlled pagination
92
+
93
+ In this mode, the component assumes that the input data is not paginated. The component will implement the pagination logic and apply it to the input data
94
+ then inject the paged data into direct child components. This is the default mode of operations for the component where `externallyControlled` prop is set
95
+ to `false`.
96
+ */
97
+ declare const TablePagination: (props: Props) => React.JSX.Element;
98
+ export default TablePagination;
@@ -0,0 +1,24 @@
1
+ import { ButtonProps } from "../../Button";
2
+ import { HTMLAttributes } from "react";
3
+ import { BasePaginationProps, ExternalControlProps, InternalControlProps } from "../TablePagination";
4
+ export declare enum Label {
5
+ NEXT_PAGE = "Next page",
6
+ PREVIOUS_PAGE = "Previous page",
7
+ PAGE_NUMBER = "Page number"
8
+ }
9
+ export type AllProps = BasePaginationProps & InternalControlProps & ExternalControlProps;
10
+ export type Props = Omit<AllProps, "currentPage" | "data" | "dataForwardProp" | "externallyControlled" | "onPageChange" | "position" | "totalItems"> & {
11
+ currentPage?: AllProps["currentPage"];
12
+ displayDescription?: boolean;
13
+ onInputPageChange?: (page: number) => void;
14
+ nextButtonProps?: Partial<ButtonProps>;
15
+ onNextPage?: (page: number) => void;
16
+ onPageChange?: AllProps["onPageChange"];
17
+ onPreviousPage?: (page: number) => void;
18
+ previousButtonProps?: Partial<ButtonProps>;
19
+ totalItems?: AllProps["totalItems"];
20
+ visibleCount?: number;
21
+ showPageInput?: boolean;
22
+ } & HTMLAttributes<HTMLDivElement>;
23
+ declare const TablePaginationControls: ({ className, currentPage, description, displayDescription, onInputPageChange, itemName, nextButtonProps, onNextPage, onPageChange, onPageSizeChange, onPreviousPage, pageLimits, pageSize, previousButtonProps, showPageInput, totalItems, visibleCount, ...divProps }: Props) => JSX.Element;
24
+ export default TablePaginationControls;
@@ -0,0 +1,2 @@
1
+ export { default } from "./TablePaginationControls";
2
+ export type { Props as TablePaginationControlsProps } from "./TablePaginationControls";
@@ -0,0 +1,2 @@
1
+ export { default } from "./TablePagination";
2
+ export type { Props as TablePaginationProps } from "./TablePagination";
@@ -0,0 +1,27 @@
1
+ import { ReactElement, ReactNode } from "react";
2
+ /**
3
+ * Determine if we are working with a small screen.
4
+ * 'small screen' in this case is relative to the width of the description div
5
+ */
6
+ export declare const figureSmallScreen: () => boolean;
7
+ /**
8
+ * Iterate direct react child components and override the value of the prop specified by @param dataForwardProp
9
+ * for those child components.
10
+ * @param children - react node children to iterate
11
+ * @param dataForwardProp - the name of the prop from the children components to override
12
+ * @param data - actual data to be passed to the prop specified by @param dataForwardProp
13
+ */
14
+ export declare const renderChildren: (children: ReactNode, dataForwardProp: string, data: unknown[]) => ReactElement<any, string | import("react").JSXElementConstructor<any>>[];
15
+ export declare const DEFAULT_PAGE_LIMITS: number[];
16
+ export declare const generatePagingOptions: (pageLimits: number[]) => {
17
+ value: number;
18
+ label: string;
19
+ }[];
20
+ export declare const getDescription: ({ description, isSmallScreen, totalItems, itemName, visibleCount, }: {
21
+ description: ReactNode;
22
+ isSmallScreen: boolean;
23
+ totalItems: number;
24
+ itemName: string;
25
+ visibleCount: number;
26
+ }) => string | number | true | ReactElement<any, string | import("react").JSXElementConstructor<any>> | Iterable<ReactNode>;
27
+ export declare const useFigureSmallScreen: () => boolean;
@@ -0,0 +1,10 @@
1
+ import type { HTMLProps, ReactNode } from "react";
2
+ import type { PropsWithSpread } from "../../types";
3
+ export type Props = PropsWithSpread<{
4
+ /**
5
+ * The content of the table row.
6
+ */
7
+ children: ReactNode;
8
+ }, HTMLProps<HTMLTableRowElement>>;
9
+ declare const TableRow: ({ children, ...trProps }: Props) => JSX.Element;
10
+ export default TableRow;
@@ -0,0 +1,2 @@
1
+ export { default } from "./TableRow";
2
+ export type { Props as TableRowProps } from "./TableRow";
@@ -0,0 +1,45 @@
1
+ import type { HTMLProps, ElementType, ReactNode, ComponentType } from "react";
2
+ import type { ClassName } from "../../types";
3
+ export type TabLink<P = null> = {
4
+ /**
5
+ * Whether the tab link should have active styling.
6
+ */
7
+ active?: boolean;
8
+ /**
9
+ * Optional classes applied to the link element.
10
+ */
11
+ className?: ClassName;
12
+ /**
13
+ * Optional component to be used instead of the default "a" element.
14
+ */
15
+ component?: ElementType | ComponentType<P>;
16
+ /**
17
+ * Label to be displayed inside the tab link.
18
+ */
19
+ label: ReactNode;
20
+ /**
21
+ * Optional classes applied to the "li" element.
22
+ */
23
+ listItemClassName?: string;
24
+ } & (HTMLProps<HTMLElement> | P);
25
+ export type Props<P = null> = {
26
+ /**
27
+ * Optional classes applied to the parent "nav" element.
28
+ */
29
+ className?: ClassName;
30
+ /**
31
+ * An array of tab link objects.
32
+ */
33
+ links: TabLink<P>[];
34
+ /**
35
+ * Optional classes applied to the "ul" element.
36
+ */
37
+ listClassName?: string;
38
+ };
39
+ /**
40
+ * This is the [React](https://reactjs.org/) component for Vanilla [Tabs](https://vanillaframework.io/docs/patterns/tabs).
41
+ Tabs organise and allow navigation between groups of content that are related and at the same level
42
+ of hierarchy.
43
+ */
44
+ declare const Tabs: <P>({ className, links, listClassName, }: Props<P>) => JSX.Element;
45
+ export default Tabs;
@@ -0,0 +1,2 @@
1
+ export { default } from "./Tabs";
2
+ export type { Props as TabsProps } from "./Tabs";
@@ -0,0 +1,70 @@
1
+ import type { TextareaHTMLAttributes, ReactNode } from "react";
2
+ import type { ClassName, PropsWithSpread } from "../../types";
3
+ /**
4
+ * The props for the Textarea component.
5
+ */
6
+ export type Props = PropsWithSpread<{
7
+ /**
8
+ * The content for caution validation.
9
+ */
10
+ caution?: ReactNode;
11
+ /**
12
+ * Optional class(es) to pass to the textarea element.
13
+ */
14
+ className?: ClassName;
15
+ /**
16
+ * The content for error validation.
17
+ */
18
+ error?: ReactNode;
19
+ /**
20
+ * Whether the textarea should grow to fit the content automatically.
21
+ */
22
+ grow?: boolean;
23
+ /**
24
+ * Help text to show below the field.
25
+ */
26
+ help?: ReactNode;
27
+ /**
28
+ * The id of the textarea.
29
+ */
30
+ id?: string;
31
+ /**
32
+ * The label for the field.
33
+ */
34
+ label?: ReactNode;
35
+ /**
36
+ * Optional class(es) to pass to the label component.
37
+ */
38
+ labelClassName?: string;
39
+ /**
40
+ * Whether the field is required.
41
+ */
42
+ required?: boolean;
43
+ /**
44
+ * Whether the form field should have a stacked appearance.
45
+ */
46
+ stacked?: boolean;
47
+ /**
48
+ * The content for success validation.
49
+ */
50
+ success?: ReactNode;
51
+ /**
52
+ * Whether to focus on the input on initial render.
53
+ */
54
+ takeFocus?: boolean;
55
+ /**
56
+ * Optional class(es) to pass to the wrapping Field component
57
+ */
58
+ wrapperClassName?: string;
59
+ /**
60
+ * Function to occur on keyboard event, 'CTRL + Enter'
61
+ */
62
+ onControlEnter?: () => void;
63
+ }, TextareaHTMLAttributes<HTMLTextAreaElement>>;
64
+ /**
65
+ * This is a [React](https://reactjs.org/) component for the Vanilla [Textarea](https://docs.vanillaframework.io/base/forms/#textarea).
66
+ *
67
+ * The Textarea component defines a multi-line text input control.
68
+ */
69
+ declare const Textarea: ({ caution, className, error, grow, help, id, label, labelClassName, onKeyUp, onControlEnter, required, stacked, style, success, takeFocus, wrapperClassName, ...props }: Props) => JSX.Element;
70
+ export default Textarea;
@@ -0,0 +1,2 @@
1
+ export { default } from "./Textarea";
2
+ export type { Props as TextareaProps } from "./Textarea";