@canonical/react-components 1.2.4 → 1.3.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 (287) hide show
  1. package/README.md +2 -2
  2. package/package.json +9 -6
  3. package/dist/components/Accordion/Accordion.d.ts +0 -46
  4. package/dist/components/Accordion/Accordion.stories.d.ts +0 -18
  5. package/dist/components/Accordion/Accordion.stories.js +0 -117
  6. package/dist/components/Accordion/AccordionSection/AccordionSection.d.ts +0 -34
  7. package/dist/components/Accordion/AccordionSection/index.d.ts +0 -2
  8. package/dist/components/Accordion/index.d.ts +0 -2
  9. package/dist/components/ActionButton/ActionButton.d.ts +0 -48
  10. package/dist/components/ActionButton/ActionButton.stories.d.ts +0 -7
  11. package/dist/components/ActionButton/ActionButton.stories.js +0 -36
  12. package/dist/components/ActionButton/index.d.ts +0 -2
  13. package/dist/components/ApplicationLayout/AppAside/AppAside.d.ts +0 -33
  14. package/dist/components/ApplicationLayout/AppAside/AppAside.stories.d.ts +0 -13
  15. package/dist/components/ApplicationLayout/AppAside/AppAside.stories.js +0 -116
  16. package/dist/components/ApplicationLayout/AppAside/index.d.ts +0 -2
  17. package/dist/components/ApplicationLayout/AppMain/AppMain.d.ts +0 -14
  18. package/dist/components/ApplicationLayout/AppMain/AppMain.stories.d.ts +0 -14
  19. package/dist/components/ApplicationLayout/AppMain/AppMain.stories.js +0 -45
  20. package/dist/components/ApplicationLayout/AppMain/index.d.ts +0 -2
  21. package/dist/components/ApplicationLayout/AppNavigation/AppNavigation.d.ts +0 -26
  22. package/dist/components/ApplicationLayout/AppNavigation/AppNavigation.stories.d.ts +0 -12
  23. package/dist/components/ApplicationLayout/AppNavigation/AppNavigation.stories.js +0 -104
  24. package/dist/components/ApplicationLayout/AppNavigation/index.d.ts +0 -2
  25. package/dist/components/ApplicationLayout/AppNavigationBar/AppNavigationBar.d.ts +0 -18
  26. package/dist/components/ApplicationLayout/AppNavigationBar/AppNavigationBar.stories.d.ts +0 -15
  27. package/dist/components/ApplicationLayout/AppNavigationBar/AppNavigationBar.stories.js +0 -52
  28. package/dist/components/ApplicationLayout/AppNavigationBar/index.d.ts +0 -2
  29. package/dist/components/ApplicationLayout/AppStatus/AppStatus.d.ts +0 -14
  30. package/dist/components/ApplicationLayout/AppStatus/AppStatus.stories.d.ts +0 -13
  31. package/dist/components/ApplicationLayout/AppStatus/AppStatus.stories.js +0 -41
  32. package/dist/components/ApplicationLayout/AppStatus/index.d.ts +0 -2
  33. package/dist/components/ApplicationLayout/Application/Application.d.ts +0 -15
  34. package/dist/components/ApplicationLayout/Application/Application.stories.d.ts +0 -6
  35. package/dist/components/ApplicationLayout/Application/Application.stories.js +0 -16
  36. package/dist/components/ApplicationLayout/Application/index.d.ts +0 -2
  37. package/dist/components/ApplicationLayout/ApplicationLayout.d.ts +0 -89
  38. package/dist/components/ApplicationLayout/ApplicationLayout.stories.d.ts +0 -24
  39. package/dist/components/ApplicationLayout/ApplicationLayout.stories.js +0 -232
  40. package/dist/components/ApplicationLayout/index.d.ts +0 -7
  41. package/dist/components/ArticlePagination/ArticlePagination.d.ts +0 -31
  42. package/dist/components/ArticlePagination/ArticlePagination.stories.d.ts +0 -6
  43. package/dist/components/ArticlePagination/ArticlePagination.stories.js +0 -22
  44. package/dist/components/ArticlePagination/index.d.ts +0 -2
  45. package/dist/components/Badge/Badge.d.ts +0 -34
  46. package/dist/components/Badge/Badge.stories.d.ts +0 -15
  47. package/dist/components/Badge/Badge.stories.js +0 -62
  48. package/dist/components/Badge/index.d.ts +0 -2
  49. package/dist/components/Button/Button.d.ts +0 -64
  50. package/dist/components/Button/Button.stories.d.ts +0 -32
  51. package/dist/components/Button/Button.stories.js +0 -180
  52. package/dist/components/Button/index.d.ts +0 -2
  53. package/dist/components/Card/Card.d.ts +0 -35
  54. package/dist/components/Card/Card.stories.d.ts +0 -33
  55. package/dist/components/Card/Card.stories.js +0 -51
  56. package/dist/components/Card/index.d.ts +0 -2
  57. package/dist/components/CheckboxInput/CheckableInput/CheckableInput.d.ts +0 -27
  58. package/dist/components/CheckboxInput/CheckableInput/index.d.ts +0 -2
  59. package/dist/components/CheckboxInput/CheckboxInput.d.ts +0 -9
  60. package/dist/components/CheckboxInput/CheckboxInput.stories.d.ts +0 -11
  61. package/dist/components/CheckboxInput/CheckboxInput.stories.js +0 -84
  62. package/dist/components/CheckboxInput/index.d.ts +0 -2
  63. package/dist/components/Chip/Chip.d.ts +0 -56
  64. package/dist/components/Chip/Chip.stories.d.ts +0 -9
  65. package/dist/components/Chip/Chip.stories.js +0 -45
  66. package/dist/components/Chip/index.d.ts +0 -2
  67. package/dist/components/Code/Code.d.ts +0 -13
  68. package/dist/components/Code/index.d.ts +0 -2
  69. package/dist/components/CodeSnippet/CodeSnippet.d.ts +0 -21
  70. package/dist/components/CodeSnippet/CodeSnippet.stories.d.ts +0 -45
  71. package/dist/components/CodeSnippet/CodeSnippet.stories.js +0 -279
  72. package/dist/components/CodeSnippet/CodeSnippetBlock.d.ts +0 -40
  73. package/dist/components/CodeSnippet/CodeSnippetDropdown.d.ts +0 -18
  74. package/dist/components/CodeSnippet/index.d.ts +0 -5
  75. package/dist/components/Col/Col.d.ts +0 -53
  76. package/dist/components/Col/Col.stories.d.ts +0 -11
  77. package/dist/components/Col/Col.stories.js +0 -154
  78. package/dist/components/Col/index.d.ts +0 -2
  79. package/dist/components/ConfirmationButton/ConfirmationButton.d.ts +0 -28
  80. package/dist/components/ConfirmationButton/ConfirmationButton.stories.d.ts +0 -9
  81. package/dist/components/ConfirmationButton/ConfirmationButton.stories.js +0 -108
  82. package/dist/components/ConfirmationButton/index.d.ts +0 -2
  83. package/dist/components/ConfirmationModal/ConfirmationModal.d.ts +0 -53
  84. package/dist/components/ConfirmationModal/ConfirmationModal.stories.d.ts +0 -18
  85. package/dist/components/ConfirmationModal/ConfirmationModal.stories.js +0 -135
  86. package/dist/components/ConfirmationModal/index.d.ts +0 -2
  87. package/dist/components/ContextualMenu/ContextualMenu.d.ts +0 -110
  88. package/dist/components/ContextualMenu/ContextualMenu.stories.d.ts +0 -13
  89. package/dist/components/ContextualMenu/ContextualMenu.stories.js +0 -107
  90. package/dist/components/ContextualMenu/ContextualMenuDropdown/ContextualMenuDropdown.d.ts +0 -43
  91. package/dist/components/ContextualMenu/ContextualMenuDropdown/index.d.ts +0 -2
  92. package/dist/components/ContextualMenu/index.d.ts +0 -3
  93. package/dist/components/EmptyState/EmptyState.d.ts +0 -25
  94. package/dist/components/EmptyState/EmptyState.stories.d.ts +0 -7
  95. package/dist/components/EmptyState/EmptyState.stories.js +0 -49
  96. package/dist/components/EmptyState/index.d.ts +0 -2
  97. package/dist/components/Field/Field.d.ts +0 -77
  98. package/dist/components/Field/index.d.ts +0 -2
  99. package/dist/components/Form/Form.d.ts +0 -21
  100. package/dist/components/Form/Form.stories.d.ts +0 -12
  101. package/dist/components/Form/Form.stories.js +0 -179
  102. package/dist/components/Form/index.d.ts +0 -2
  103. package/dist/components/FormikField/FormikField.d.ts +0 -25
  104. package/dist/components/FormikField/FormikField.stories.d.ts +0 -8
  105. package/dist/components/FormikField/FormikField.stories.js +0 -85
  106. package/dist/components/FormikField/index.d.ts +0 -1
  107. package/dist/components/Icon/Icon.d.ts +0 -59
  108. package/dist/components/Icon/Icon.stories.d.ts +0 -16
  109. package/dist/components/Icon/Icon.stories.js +0 -49
  110. package/dist/components/Icon/index.d.ts +0 -2
  111. package/dist/components/Input/Input.d.ts +0 -70
  112. package/dist/components/Input/Input.stories.d.ts +0 -14
  113. package/dist/components/Input/Input.stories.js +0 -148
  114. package/dist/components/Input/index.d.ts +0 -2
  115. package/dist/components/Label/Label.d.ts +0 -25
  116. package/dist/components/Label/index.d.ts +0 -2
  117. package/dist/components/Link/Link.d.ts +0 -31
  118. package/dist/components/Link/Link.stories.d.ts +0 -9
  119. package/dist/components/Link/Link.stories.js +0 -48
  120. package/dist/components/Link/index.d.ts +0 -2
  121. package/dist/components/List/List.d.ts +0 -36
  122. package/dist/components/List/List.stories.d.ts +0 -15
  123. package/dist/components/List/List.stories.js +0 -122
  124. package/dist/components/List/index.d.ts +0 -2
  125. package/dist/components/Loader/Loader.d.ts +0 -6
  126. package/dist/components/Loader/index.d.ts +0 -1
  127. package/dist/components/LoginPageLayout/LoginPageLayout.d.ts +0 -17
  128. package/dist/components/LoginPageLayout/LoginPageLayout.stories.d.ts +0 -9
  129. package/dist/components/LoginPageLayout/LoginPageLayout.stories.js +0 -58
  130. package/dist/components/LoginPageLayout/index.d.ts +0 -2
  131. package/dist/components/MainTable/MainTable.d.ts +0 -102
  132. package/dist/components/MainTable/MainTable.stories.d.ts +0 -15
  133. package/dist/components/MainTable/MainTable.stories.js +0 -553
  134. package/dist/components/MainTable/index.d.ts +0 -2
  135. package/dist/components/Modal/Modal.d.ts +0 -36
  136. package/dist/components/Modal/Modal.stories.d.ts +0 -6
  137. package/dist/components/Modal/Modal.stories.js +0 -57
  138. package/dist/components/Modal/index.d.ts +0 -2
  139. package/dist/components/ModularTable/ModularTable.d.ts +0 -105
  140. package/dist/components/ModularTable/ModularTable.stories.d.ts +0 -27
  141. package/dist/components/ModularTable/ModularTable.stories.js +0 -343
  142. package/dist/components/ModularTable/index.d.ts +0 -2
  143. package/dist/components/MultiSelect/FadeInDown/FadeInDown.d.ts +0 -10
  144. package/dist/components/MultiSelect/FadeInDown/index.d.ts +0 -1
  145. package/dist/components/MultiSelect/MultiSelect.d.ts +0 -57
  146. package/dist/components/MultiSelect/MultiSelect.stories.d.ts +0 -8
  147. package/dist/components/MultiSelect/MultiSelect.stories.js +0 -70
  148. package/dist/components/MultiSelect/index.d.ts +0 -1
  149. package/dist/components/Navigation/Navigation.d.ts +0 -66
  150. package/dist/components/Navigation/Navigation.stories.d.ts +0 -43
  151. package/dist/components/Navigation/Navigation.stories.js +0 -232
  152. package/dist/components/Navigation/NavigationLink/NavigationLink.d.ts +0 -10
  153. package/dist/components/Navigation/NavigationLink/index.d.ts +0 -1
  154. package/dist/components/Navigation/NavigationMenu/NavigationMenu.d.ts +0 -11
  155. package/dist/components/Navigation/NavigationMenu/index.d.ts +0 -1
  156. package/dist/components/Navigation/index.d.ts +0 -3
  157. package/dist/components/Navigation/types.d.ts +0 -64
  158. package/dist/components/Notification/Notification.d.ts +0 -110
  159. package/dist/components/Notification/Notification.stories.d.ts +0 -45
  160. package/dist/components/Notification/Notification.stories.js +0 -201
  161. package/dist/components/Notification/index.d.ts +0 -2
  162. package/dist/components/NotificationProvider/NotificationProvider.d.ts +0 -5
  163. package/dist/components/NotificationProvider/index.d.ts +0 -3
  164. package/dist/components/NotificationProvider/messageBuilder.d.ts +0 -6
  165. package/dist/components/NotificationProvider/types.d.ts +0 -35
  166. package/dist/components/Pagination/Pagination.d.ts +0 -102
  167. package/dist/components/Pagination/Pagination.stories.d.ts +0 -14
  168. package/dist/components/Pagination/Pagination.stories.js +0 -94
  169. package/dist/components/Pagination/PaginationButton/PaginationButton.d.ts +0 -30
  170. package/dist/components/Pagination/PaginationButton/index.d.ts +0 -2
  171. package/dist/components/Pagination/PaginationItem/PaginationItem.d.ts +0 -17
  172. package/dist/components/Pagination/PaginationItem/index.d.ts +0 -2
  173. package/dist/components/Pagination/index.d.ts +0 -2
  174. package/dist/components/Panel/Panel.d.ts +0 -123
  175. package/dist/components/Panel/Panel.stories.d.ts +0 -17
  176. package/dist/components/Panel/Panel.stories.js +0 -60
  177. package/dist/components/Panel/index.d.ts +0 -1
  178. package/dist/components/PasswordToggle/PasswordToggle.d.ts +0 -108
  179. package/dist/components/PasswordToggle/PasswordToggle.stories.d.ts +0 -12
  180. package/dist/components/PasswordToggle/PasswordToggle.stories.js +0 -74
  181. package/dist/components/PasswordToggle/index.d.ts +0 -2
  182. package/dist/components/RadioInput/RadioInput.d.ts +0 -9
  183. package/dist/components/RadioInput/RadioInput.stories.d.ts +0 -10
  184. package/dist/components/RadioInput/RadioInput.stories.js +0 -83
  185. package/dist/components/RadioInput/index.d.ts +0 -2
  186. package/dist/components/Row/Row.d.ts +0 -19
  187. package/dist/components/Row/Row.stories.d.ts +0 -9
  188. package/dist/components/Row/Row.stories.js +0 -29
  189. package/dist/components/Row/index.d.ts +0 -2
  190. package/dist/components/SearchAndFilter/FilterPanelSection/FilterPanelSection.d.ts +0 -25
  191. package/dist/components/SearchAndFilter/FilterPanelSection/index.d.ts +0 -1
  192. package/dist/components/SearchAndFilter/SearchAndFilter.d.ts +0 -33
  193. package/dist/components/SearchAndFilter/SearchAndFilter.stories.d.ts +0 -8
  194. package/dist/components/SearchAndFilter/SearchAndFilter.stories.js +0 -218
  195. package/dist/components/SearchAndFilter/index.d.ts +0 -2
  196. package/dist/components/SearchAndFilter/types.d.ts +0 -11
  197. package/dist/components/SearchAndFilter/utils.d.ts +0 -13
  198. package/dist/components/SearchBox/SearchBox.d.ts +0 -63
  199. package/dist/components/SearchBox/SearchBox.stories.d.ts +0 -14
  200. package/dist/components/SearchBox/SearchBox.stories.js +0 -106
  201. package/dist/components/SearchBox/index.d.ts +0 -2
  202. package/dist/components/Select/Select.d.ts +0 -71
  203. package/dist/components/Select/Select.stories.d.ts +0 -7
  204. package/dist/components/Select/Select.stories.js +0 -97
  205. package/dist/components/Select/index.d.ts +0 -2
  206. package/dist/components/SideNavigation/SideNavigation.d.ts +0 -50
  207. package/dist/components/SideNavigation/SideNavigation.stories.d.ts +0 -14
  208. package/dist/components/SideNavigation/SideNavigation.stories.js +0 -62
  209. package/dist/components/SideNavigation/SideNavigationBase/SideNavigationBase.d.ts +0 -31
  210. package/dist/components/SideNavigation/SideNavigationBase/index.d.ts +0 -1
  211. package/dist/components/SideNavigation/SideNavigationItem/SideNavigationItem.d.ts +0 -20
  212. package/dist/components/SideNavigation/SideNavigationItem/SideNavigationItem.stories.d.ts +0 -22
  213. package/dist/components/SideNavigation/SideNavigationItem/SideNavigationItem.stories.js +0 -70
  214. package/dist/components/SideNavigation/SideNavigationItem/index.d.ts +0 -1
  215. package/dist/components/SideNavigation/SideNavigationLink/SideNavigationLink.d.ts +0 -21
  216. package/dist/components/SideNavigation/SideNavigationLink/SideNavigationLink.stories.d.ts +0 -7
  217. package/dist/components/SideNavigation/SideNavigationLink/SideNavigationLink.stories.js +0 -32
  218. package/dist/components/SideNavigation/SideNavigationLink/index.d.ts +0 -1
  219. package/dist/components/SideNavigation/SideNavigationText/SideNavigationText.d.ts +0 -7
  220. package/dist/components/SideNavigation/SideNavigationText/SideNavigationText.stories.d.ts +0 -6
  221. package/dist/components/SideNavigation/SideNavigationText/SideNavigationText.stories.js +0 -25
  222. package/dist/components/SideNavigation/SideNavigationText/index.d.ts +0 -1
  223. package/dist/components/SideNavigation/index.d.ts +0 -5
  224. package/dist/components/Slider/Slider.d.ts +0 -62
  225. package/dist/components/Slider/Slider.stories.d.ts +0 -10
  226. package/dist/components/Slider/Slider.stories.js +0 -74
  227. package/dist/components/Slider/index.d.ts +0 -2
  228. package/dist/components/Spinner/Spinner.d.ts +0 -29
  229. package/dist/components/Spinner/Spinner.stories.d.ts +0 -8
  230. package/dist/components/Spinner/Spinner.stories.js +0 -28
  231. package/dist/components/Spinner/index.d.ts +0 -2
  232. package/dist/components/StatusLabel/StatusLabel.d.ts +0 -33
  233. package/dist/components/StatusLabel/StatusLabel.stories.d.ts +0 -10
  234. package/dist/components/StatusLabel/StatusLabel.stories.js +0 -61
  235. package/dist/components/StatusLabel/index.d.ts +0 -2
  236. package/dist/components/Strip/Strip.d.ts +0 -64
  237. package/dist/components/Strip/Strip.stories.d.ts +0 -12
  238. package/dist/components/Strip/Strip.stories.js +0 -130
  239. package/dist/components/Strip/index.d.ts +0 -2
  240. package/dist/components/SummaryButton/SummaryButton.d.ts +0 -29
  241. package/dist/components/SummaryButton/SummaryButton.stories.d.ts +0 -18
  242. package/dist/components/SummaryButton/SummaryButton.stories.js +0 -59
  243. package/dist/components/SummaryButton/index.d.ts +0 -2
  244. package/dist/components/Switch/Switch.d.ts +0 -17
  245. package/dist/components/Switch/Switch.stories.d.ts +0 -7
  246. package/dist/components/Switch/Switch.stories.js +0 -26
  247. package/dist/components/Switch/index.d.ts +0 -2
  248. package/dist/components/Table/Table.d.ts +0 -22
  249. package/dist/components/Table/index.d.ts +0 -2
  250. package/dist/components/TableCell/TableCell.d.ts +0 -26
  251. package/dist/components/TableCell/index.d.ts +0 -2
  252. package/dist/components/TableHeader/TableHeader.d.ts +0 -14
  253. package/dist/components/TableHeader/index.d.ts +0 -2
  254. package/dist/components/TablePagination/TablePagination.d.ts +0 -98
  255. package/dist/components/TablePagination/TablePagination.stories.d.ts +0 -14
  256. package/dist/components/TablePagination/TablePagination.stories.js +0 -330
  257. package/dist/components/TablePagination/TablePaginationControls/TablePaginationControls.d.ts +0 -24
  258. package/dist/components/TablePagination/TablePaginationControls/index.d.ts +0 -2
  259. package/dist/components/TablePagination/index.d.ts +0 -2
  260. package/dist/components/TablePagination/utils.d.ts +0 -27
  261. package/dist/components/TableRow/TableRow.d.ts +0 -10
  262. package/dist/components/TableRow/index.d.ts +0 -2
  263. package/dist/components/Tabs/Tabs.d.ts +0 -45
  264. package/dist/components/Tabs/Tabs.stories.d.ts +0 -11
  265. package/dist/components/Tabs/Tabs.stories.js +0 -56
  266. package/dist/components/Tabs/index.d.ts +0 -2
  267. package/dist/components/Textarea/Textarea.d.ts +0 -70
  268. package/dist/components/Textarea/Textarea.stories.d.ts +0 -7
  269. package/dist/components/Textarea/Textarea.stories.js +0 -62
  270. package/dist/components/Textarea/index.d.ts +0 -2
  271. package/dist/components/Tooltip/Tooltip.d.ts +0 -75
  272. package/dist/components/Tooltip/Tooltip.stories.d.ts +0 -12
  273. package/dist/components/Tooltip/Tooltip.stories.js +0 -71
  274. package/dist/components/Tooltip/index.d.ts +0 -2
  275. package/dist/enums.d.ts +0 -13
  276. package/dist/hooks/index.d.ts +0 -9
  277. package/dist/hooks/useId.d.ts +0 -4
  278. package/dist/hooks/useListener.d.ts +0 -11
  279. package/dist/hooks/useOnClickOutside.d.ts +0 -12
  280. package/dist/hooks/useOnEscapePressed.d.ts +0 -6
  281. package/dist/hooks/usePagination.d.ts +0 -19
  282. package/dist/hooks/usePrevious.d.ts +0 -7
  283. package/dist/hooks/useThrottle.d.ts +0 -9
  284. package/dist/hooks/useWindowFitment.d.ts +0 -54
  285. package/dist/index.d.ts +0 -132
  286. package/dist/types/index.d.ts +0 -38
  287. package/dist/utils.d.ts +0 -27
@@ -1,60 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.default = exports.Logo = exports.Header = exports.Default = exports.CustomHeader = void 0;
7
- var _react = _interopRequireDefault(require("react"));
8
- var _Panel = _interopRequireDefault(require("./Panel"));
9
- var _Button = _interopRequireDefault(require("../Button"));
10
- var _Icon = _interopRequireDefault(require("../Icon"));
11
- function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
12
- const meta = {
13
- component: _Panel.default,
14
- tags: ["autodocs"]
15
- };
16
- var _default = exports.default = meta;
17
- const Default = exports.Default = {
18
- args: {
19
- children: "Panel content",
20
- title: "Panel"
21
- }
22
- };
23
- const Header = exports.Header = {
24
- args: {
25
- controls: /*#__PURE__*/_react.default.createElement(_Button.default, {
26
- appearance: "positive"
27
- }, /*#__PURE__*/_react.default.createElement(_Icon.default, {
28
- name: "plus",
29
- light: true
30
- }), " Create"),
31
- title: "Panel title",
32
- titleComponent: "h1"
33
- }
34
- };
35
-
36
- /**
37
- * The logo may be provided as attributes to use the standard logo. If this is
38
- * not sufficient the a `ReactNode` can be passed to the `logo` prop instead.
39
- */
40
- const Logo = exports.Logo = {
41
- args: {
42
- logo: {
43
- icon: "https://assets.ubuntu.com/v1/7144ec6d-logo-jaas-icon.svg",
44
- name: "https://assets.ubuntu.com/v1/a85f7947-juju_black-text-only.svg",
45
- nameAlt: "Juju"
46
- }
47
- }
48
- };
49
-
50
- /**
51
- * If the default header does not meet your needs then a `ReactNode` can be
52
- * passed to the `header` prop to replace the header.
53
- */
54
- const CustomHeader = exports.CustomHeader = {
55
- args: {
56
- header: /*#__PURE__*/_react.default.createElement("div", {
57
- className: "p-panel__header"
58
- }, "This header replaces the entire header area")
59
- }
60
- };
@@ -1 +0,0 @@
1
- export { default, type Props as PanelProps, type LogoDefaultElement as PanelLogoDefaultElement, } from "./Panel";
@@ -1,108 +0,0 @@
1
- import React from "react";
2
- import type { InputHTMLAttributes, ReactNode } from "react";
3
- import type { ClassName, PropsWithSpread } from "../../types";
4
- export declare enum Label {
5
- Hide = "Hide",
6
- Show = "Show"
7
- }
8
- /**
9
- * The props for the Password Toggle component.
10
- */
11
- export type Props = PropsWithSpread<{
12
- /**
13
- * The content for caution validation.
14
- */
15
- caution?: ReactNode;
16
- /**
17
- * Optional class(es) to pass to the input element.
18
- */
19
- className?: ClassName;
20
- /**
21
- * The content for error validation.
22
- */
23
- error?: ReactNode;
24
- /**
25
- * Help text to show below the field.
26
- */
27
- help?: ReactNode;
28
- /**
29
- * The id of the input.
30
- */
31
- id: string;
32
- /**
33
- * The label for the field.
34
- */
35
- label?: ReactNode;
36
- /**
37
- * Whether the field is read only.
38
- */
39
- readOnly?: boolean;
40
- /**
41
- * Whether the field is required.
42
- */
43
- required?: boolean;
44
- /**
45
- * The content for success validation.
46
- */
47
- success?: ReactNode;
48
- /**
49
- * The content for success validation.
50
- */
51
- type?: "submit" | "reset" | "button";
52
- /**
53
- * Optional class(es) to pass to the wrapping Field component
54
- */
55
- wrapperClassName?: string;
56
- }, InputHTMLAttributes<HTMLInputElement>>;
57
- /**
58
- * This is a [React](https://reactjs.org/) component for the Vanilla [Password Toggle](https://docs.vanillaframework.io/base/forms/#password-toggle).
59
- *
60
- * It can be used when an input needs to obscure its value, whilst giving the user a way to reveal it if needed.
61
- */
62
- declare const PasswordToggle: React.ForwardRefExoticComponent<{
63
- /**
64
- * The content for caution validation.
65
- */
66
- caution?: ReactNode;
67
- /**
68
- * Optional class(es) to pass to the input element.
69
- */
70
- className?: ClassName;
71
- /**
72
- * The content for error validation.
73
- */
74
- error?: ReactNode;
75
- /**
76
- * Help text to show below the field.
77
- */
78
- help?: ReactNode;
79
- /**
80
- * The id of the input.
81
- */
82
- id: string;
83
- /**
84
- * The label for the field.
85
- */
86
- label?: ReactNode;
87
- /**
88
- * Whether the field is read only.
89
- */
90
- readOnly?: boolean;
91
- /**
92
- * Whether the field is required.
93
- */
94
- required?: boolean;
95
- /**
96
- * The content for success validation.
97
- */
98
- success?: ReactNode;
99
- /**
100
- * The content for success validation.
101
- */
102
- type?: "submit" | "reset" | "button";
103
- /**
104
- * Optional class(es) to pass to the wrapping Field component
105
- */
106
- wrapperClassName?: string;
107
- } & Omit<React.InputHTMLAttributes<HTMLInputElement>, "className" | "error" | "label" | "id" | "type" | "readOnly" | "required" | "help" | "success" | "caution" | "wrapperClassName"> & React.RefAttributes<HTMLInputElement>>;
108
- export default PasswordToggle;
@@ -1,12 +0,0 @@
1
- import { Meta, StoryObj } from "@storybook/react";
2
- import PasswordToggle from "./PasswordToggle";
3
- declare const meta: Meta<typeof PasswordToggle>;
4
- export default meta;
5
- type Story = StoryObj<typeof PasswordToggle>;
6
- export declare const Default: Story;
7
- export declare const ReadOnly: Story;
8
- export declare const Error: Story;
9
- export declare const Success: Story;
10
- export declare const Caution: Story;
11
- export declare const Help: Story;
12
- export declare const Disabled: Story;
@@ -1,74 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.default = exports.Success = exports.ReadOnly = exports.Help = exports.Error = exports.Disabled = exports.Default = exports.Caution = void 0;
7
- var _react = _interopRequireDefault(require("react"));
8
- var _PasswordToggle = _interopRequireDefault(require("./PasswordToggle"));
9
- function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
10
- const meta = {
11
- component: _PasswordToggle.default,
12
- tags: ["autodocs"]
13
- };
14
- var _default = exports.default = meta;
15
- const Default = exports.Default = {
16
- render: () => /*#__PURE__*/_react.default.createElement(_PasswordToggle.default, {
17
- id: "examplePassword1",
18
- label: "Password"
19
- }),
20
- name: "Default"
21
- };
22
- const ReadOnly = exports.ReadOnly = {
23
- render: () => /*#__PURE__*/_react.default.createElement(_PasswordToggle.default, {
24
- id: "examplePassword2",
25
- label: "Password",
26
- readOnly: true,
27
- defaultValue: "password"
28
- }),
29
- name: "Read only"
30
- };
31
- const Error = exports.Error = {
32
- render: () => /*#__PURE__*/_react.default.createElement(_PasswordToggle.default, {
33
- error: "This field is required.",
34
- id: "examplePassword3",
35
- label: "Password",
36
- defaultValue: "password"
37
- }),
38
- name: "Error"
39
- };
40
- const Success = exports.Success = {
41
- render: () => /*#__PURE__*/_react.default.createElement(_PasswordToggle.default, {
42
- success: "Strong password",
43
- id: "examplePassword4",
44
- label: "Password",
45
- defaultValue: "password"
46
- }),
47
- name: "Success"
48
- };
49
- const Caution = exports.Caution = {
50
- render: () => /*#__PURE__*/_react.default.createElement(_PasswordToggle.default, {
51
- caution: "Weak password",
52
- id: "examplePassword5",
53
- label: "Password",
54
- defaultValue: "password"
55
- }),
56
- name: "Caution"
57
- };
58
- const Help = exports.Help = {
59
- render: () => /*#__PURE__*/_react.default.createElement(_PasswordToggle.default, {
60
- help: "Enter a secure password",
61
- id: "examplePassword6",
62
- label: "Password"
63
- }),
64
- name: "Help"
65
- };
66
- const Disabled = exports.Disabled = {
67
- render: () => /*#__PURE__*/_react.default.createElement(_PasswordToggle.default, {
68
- disabled: true,
69
- id: "examplePassword7",
70
- label: "Password",
71
- defaultValue: "password"
72
- }),
73
- name: "Disabled"
74
- };
@@ -1,2 +0,0 @@
1
- export { default } from "./PasswordToggle";
2
- export type { Props as PasswordToggleProps } from "./PasswordToggle";
@@ -1,9 +0,0 @@
1
- import type { CheckableInputProps } from "../CheckboxInput/CheckableInput";
2
- export type Props = Omit<CheckableInputProps, "inputType">;
3
- /**
4
- * This is a [React](https://reactjs.org/) component for the Vanilla [Radio input](https://docs.vanillaframework.io/base/forms#radio-button).
5
- *
6
- * Use radio buttons to select one of the given set of options.
7
- */
8
- declare const RadioInput: ({ label, ...radioProps }: Props) => JSX.Element;
9
- export default RadioInput;
@@ -1,10 +0,0 @@
1
- import { Meta, StoryObj } from "@storybook/react";
2
- import RadioInput from "./RadioInput";
3
- declare const meta: Meta<typeof RadioInput>;
4
- export default meta;
5
- type Story = StoryObj<typeof RadioInput>;
6
- export declare const Default: Story;
7
- export declare const Children: Story;
8
- export declare const Disabled: Story;
9
- export declare const Required: Story;
10
- export declare const Inline: Story;
@@ -1,83 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.default = exports.Required = exports.Inline = exports.Disabled = exports.Default = exports.Children = void 0;
7
- var _react = _interopRequireDefault(require("react"));
8
- var _RadioInput = _interopRequireDefault(require("./RadioInput"));
9
- function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
10
- const meta = {
11
- component: _RadioInput.default,
12
- tags: ["autodocs"],
13
- argTypes: {
14
- label: {
15
- control: {
16
- type: "text"
17
- }
18
- },
19
- disabled: {
20
- control: {
21
- type: "boolean"
22
- }
23
- },
24
- required: {
25
- control: {
26
- type: "boolean"
27
- }
28
- },
29
- inline: {
30
- control: {
31
- type: "boolean"
32
- }
33
- },
34
- indeterminate: {
35
- control: {
36
- type: "boolean"
37
- }
38
- }
39
- },
40
- args: {
41
- label: "RadioInput"
42
- }
43
- };
44
- var _default = exports.default = meta;
45
- const Default = exports.Default = {
46
- render: () => /*#__PURE__*/_react.default.createElement(_RadioInput.default, {
47
- label: "RadioInput"
48
- }),
49
- name: "Default"
50
- };
51
- const Children = exports.Children = {
52
- render: () => /*#__PURE__*/_react.default.createElement(_RadioInput.default, {
53
- label: /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, "I agree to", /*#__PURE__*/_react.default.createElement("a", {
54
- href: "http://ubuntu.com/legal"
55
- }, "Terms and Conditions")),
56
- name: "RadioInput"
57
- }),
58
- name: "Children"
59
- };
60
- const Disabled = exports.Disabled = {
61
- render: () => /*#__PURE__*/_react.default.createElement(_RadioInput.default, {
62
- label: "Disabled",
63
- name: "RadioInput",
64
- disabled: true
65
- }),
66
- name: "Disabled"
67
- };
68
- const Required = exports.Required = {
69
- render: () => /*#__PURE__*/_react.default.createElement(_RadioInput.default, {
70
- label: "Required",
71
- name: "RadioInput",
72
- required: true
73
- }),
74
- name: "Required"
75
- };
76
- const Inline = exports.Inline = {
77
- render: () => /*#__PURE__*/_react.default.createElement(_RadioInput.default, {
78
- label: "Inline",
79
- name: "RadioInput",
80
- inline: true
81
- }),
82
- name: "Inline"
83
- };
@@ -1,2 +0,0 @@
1
- export { default } from "./RadioInput";
2
- export type { Props as RadioInputProps } from "./RadioInput";
@@ -1,19 +0,0 @@
1
- import type { HTMLProps, ReactNode } from "react";
2
- import type { ClassName, PropsWithSpread } from "../../types";
3
- export type Props = PropsWithSpread<{
4
- /**
5
- * The content of the row.
6
- */
7
- children: ReactNode;
8
- /**
9
- * Optional class(es) to pass to the wrapping div element.
10
- */
11
- className?: ClassName;
12
- }, HTMLProps<HTMLDivElement>>;
13
- /**
14
- * This is a [React](https://reactjs.org/) component for use within the Vanilla [Grid](https://docs.vanillaframework.io/patterns/grid/).
15
- *
16
- * Vanilla has a responsive grid using a combination of rows and columns.
17
- */
18
- declare const Row: ({ children, className, ...props }: Props) => JSX.Element;
19
- export default Row;
@@ -1,9 +0,0 @@
1
- import { Meta, StoryObj } from "@storybook/react";
2
- import Row from "./Row";
3
- declare const meta: Meta<typeof Row>;
4
- export default meta;
5
- type Story = StoryObj<typeof Row>;
6
- /**
7
- * See [Col](?path=/docs/components-col--docs) for grid details.
8
- */
9
- export declare const Default: Story;
@@ -1,29 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.default = exports.Default = void 0;
7
- var _Row = _interopRequireDefault(require("./Row"));
8
- function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
9
- const meta = {
10
- component: _Row.default,
11
- tags: ["autodocs"],
12
- argTypes: {
13
- children: {
14
- control: {
15
- type: "text"
16
- }
17
- }
18
- }
19
- };
20
- var _default = exports.default = meta;
21
- /**
22
- * See [Col](?path=/docs/components-col--docs) for grid details.
23
- */
24
- const Default = exports.Default = {
25
- name: "Default",
26
- args: {
27
- children: "children..."
28
- }
29
- };
@@ -1,2 +0,0 @@
1
- export { default } from "./Row";
2
- export type { Props as RowProps } from "./Row";
@@ -1,25 +0,0 @@
1
- import type { SearchAndFilterChip, SearchAndFilterData } from "../types";
2
- export type Props = {
3
- /**
4
- * The chip data to display in the panel.
5
- */
6
- data: SearchAndFilterData;
7
- /**
8
- * The current search chips.
9
- */
10
- searchData: SearchAndFilterChip[];
11
- /**
12
- * A search string.
13
- */
14
- searchTerm: string;
15
- /**
16
- * Whether the chips should be hidden.
17
- */
18
- sectionHidden?: boolean;
19
- /**
20
- * A function to toggle whether a chip is selected.
21
- */
22
- toggleSelected: (chip: SearchAndFilterChip) => void;
23
- };
24
- declare const FilterPanelSection: ({ data, searchData, searchTerm, sectionHidden, toggleSelected, }: Props) => JSX.Element;
25
- export default FilterPanelSection;
@@ -1 +0,0 @@
1
- export { default } from "./FilterPanelSection";
@@ -1,33 +0,0 @@
1
- import type { SearchAndFilterChip, SearchAndFilterData } from "./types";
2
- export declare enum Label {
3
- AddFilter = "Add filter",
4
- Clear = "Clear input",
5
- SearchAndFilter = "Search and filter"
6
- }
7
- export type Props = {
8
- /**
9
- * A list of chips to initialise inside the input.
10
- */
11
- existingSearchData?: SearchAndFilterChip[];
12
- /**
13
- * The data for the filter panel.
14
- */
15
- filterPanelData: SearchAndFilterData[];
16
- /**
17
- * A function that is called when the search data changes.
18
- */
19
- returnSearchData: (searchData: SearchAndFilterChip[]) => void;
20
- /**
21
- * A function that is called when the filter panel is shown/hidden.
22
- */
23
- onPanelToggle?: () => void;
24
- /**
25
- * A function that is called when the height of the search container changes.
26
- */
27
- onExpandChange?: () => void;
28
- };
29
- /**
30
- * This component allows searching and filtering of large datasets.
31
- */
32
- declare const SearchAndFilter: ({ existingSearchData, filterPanelData, returnSearchData, onPanelToggle, onExpandChange, ...props }: Props) => JSX.Element;
33
- export default SearchAndFilter;
@@ -1,8 +0,0 @@
1
- import { Meta, StoryObj } from "@storybook/react";
2
- import SearchAndFilter from "./SearchAndFilter";
3
- declare const meta: Meta<typeof SearchAndFilter>;
4
- export default meta;
5
- type Story = StoryObj<typeof SearchAndFilter>;
6
- export declare const Default: Story;
7
- export declare const WithDataSet: Story;
8
- export declare const WithExistingSearchData: Story;