@algolia/satellite 1.0.0-beta.161 → 1.0.0-beta.163

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 (224) hide show
  1. package/cjs/AnnouncementBadge/AnnouncementBadge.d.ts +2 -2
  2. package/cjs/AnnouncementBadge/AnnouncementBadge.js +7 -3
  3. package/cjs/AutoComplete/AutoComplete.d.ts +1 -1
  4. package/cjs/AutoComplete/AutoComplete.tailwind.js +1 -1
  5. package/cjs/AutoComplete/components/AutoCompleteEmptyState.d.ts +3 -3
  6. package/cjs/AutoComplete/components/DefaultOptionItem.d.ts +2 -2
  7. package/cjs/Avatars/ApplicationAvatar.d.ts +2 -2
  8. package/cjs/Avatars/UserAvatar.d.ts +2 -2
  9. package/cjs/Badge/Badge.d.ts +3 -3
  10. package/cjs/Badge/Badge.js +6 -3
  11. package/cjs/Banners/Alert/Alert.d.ts +2 -2
  12. package/cjs/Banners/BigBertha/BigBertha.d.ts +2 -2
  13. package/cjs/Banners/Promote/Promote.d.ts +2 -2
  14. package/cjs/Button/ButtonGroup.d.ts +2 -2
  15. package/cjs/Button/PolymorphicButton.d.ts +2 -1
  16. package/cjs/Button/PolymorphicButton.js +1 -0
  17. package/cjs/Button/PolymorphicIconButton.d.ts +2 -1
  18. package/cjs/Button/PolymorphicIconButton.js +1 -0
  19. package/cjs/Button/index.d.ts +1 -1
  20. package/cjs/Button/index.js +1 -17
  21. package/cjs/Card/components/CardHeader.d.ts +2 -2
  22. package/cjs/Card/components/CardTitle.d.ts +2 -2
  23. package/cjs/ClickAwayContainer/ClickAwayContainer.d.ts +2 -2
  24. package/cjs/DatePicker/DatePicker/DatePicker.d.ts +3 -3
  25. package/cjs/DatePicker/DateRangePicker/DateRangePicker.d.ts +4 -3
  26. package/cjs/DatePicker/DateRangePicker/DateRangePickerDisplay.d.ts +4 -4
  27. package/cjs/DatePicker/DateRangePicker/dateRangePickerReducer.d.ts +1 -1
  28. package/cjs/DatePicker/components/Calendar.d.ts +3 -3
  29. package/cjs/DatePicker/components/Display.d.ts +2 -2
  30. package/cjs/DatePicker/components/Footer.d.ts +2 -2
  31. package/cjs/DatePicker/components/FooterActions.d.ts +3 -3
  32. package/cjs/DatePicker/components/Modal.d.ts +2 -2
  33. package/cjs/DatePicker/components/NavBar.d.ts +3 -3
  34. package/cjs/DatePicker/components/SidePanel.d.ts +2 -2
  35. package/cjs/Dropdown/Dropdown.d.ts +21 -36
  36. package/cjs/Dropdown/DropdownButton.d.ts +3 -3
  37. package/cjs/Dropdown/components/DropdownButtonItem.d.ts +3 -8
  38. package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItem.d.ts +2 -2
  39. package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsGroup.d.ts +2 -2
  40. package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsMultiGroup.d.ts +2 -2
  41. package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsSingleGroup.d.ts +2 -2
  42. package/cjs/Dropdown/components/DropdownFooterItem.d.ts +2 -2
  43. package/cjs/Dropdown/components/DropdownLinkItem.d.ts +3 -8
  44. package/cjs/Dropdown/components/DropdownLinkItem.js +6 -1
  45. package/cjs/Dropdown/components/DropdownRadioItem.d.ts +4 -9
  46. package/cjs/Dropdown/components/DropdownTitle.d.ts +2 -2
  47. package/cjs/Dropdown/components/DropdownToggleItem.d.ts +4 -9
  48. package/cjs/Dropzone/Dropzone.d.ts +4 -3
  49. package/cjs/Dropzone/Dropzone.js +17 -18
  50. package/cjs/EmptyState/EmptyState.d.ts +2 -2
  51. package/cjs/Field/Field.d.ts +3 -3
  52. package/cjs/Flag/Flag.d.ts +2 -2
  53. package/cjs/Flag/Flags.d.ts +2 -2
  54. package/cjs/FlexGrid/FlexGrid.d.ts +2 -2
  55. package/cjs/HelpUnderline/HelpUnderline.d.ts +3 -3
  56. package/cjs/HelpUnderline/HelpUnderline.js +1 -1
  57. package/cjs/Input/Input.tailwind.js +1 -1
  58. package/cjs/Insert/Insert.d.ts +3 -3
  59. package/cjs/KeyboardKey/KeyboardKey.d.ts +2 -2
  60. package/cjs/Medallion/Medallion.d.ts +2 -2
  61. package/cjs/Modal/Modal.d.ts +7 -5
  62. package/cjs/Modal/components/ModalFooter.d.ts +2 -2
  63. package/cjs/Modal/components/ModalSection.d.ts +2 -2
  64. package/cjs/Pagination/CompactPagination/CompactPagination.d.ts +2 -2
  65. package/cjs/Pagination/Pagination/Pagination.d.ts +2 -2
  66. package/cjs/ProgressBar/ProgressBar.d.ts +2 -2
  67. package/cjs/ProgressBar/ProgressBar.js +7 -3
  68. package/cjs/ProgressSpinner/ProgressSpinner.d.ts +2 -2
  69. package/cjs/RadioGroup/RadioGroup.d.ts +6 -6
  70. package/cjs/RangeSlider/RangeSlider.d.ts +6 -4
  71. package/cjs/RangeSlider/RangeSlider.js +14 -10
  72. package/cjs/Satellite/Satellite.d.ts +2 -2
  73. package/cjs/Satellite/Satellite.js +29 -13
  74. package/cjs/Satellite/SatelliteContext.d.ts +1 -1
  75. package/cjs/Satellite/useCreatePortal.d.ts +1 -1
  76. package/cjs/ScrollIndicator/ScrollIndicator.d.ts +2 -2
  77. package/cjs/Separator/Separator.d.ts +2 -2
  78. package/cjs/Sidebar/Sidebar.d.ts +2 -2
  79. package/cjs/Sidebar/SidebarButtonLink.d.ts +2 -2
  80. package/cjs/Sidebar/SidebarButtonLink.js +2 -2
  81. package/cjs/Sidebar/SidebarHeader.d.ts +2 -2
  82. package/cjs/Sidebar/SidebarHeading.d.ts +2 -2
  83. package/cjs/Sidebar/SidebarHeading.js +1 -1
  84. package/cjs/Sidebar/SidebarLink.d.ts +2 -2
  85. package/cjs/Sidebar/SidebarLinksGroup/ActiveLinkIndicator.d.ts +2 -2
  86. package/cjs/Sidebar/SidebarLinksGroup/SidebarGroupLink.d.ts +2 -2
  87. package/cjs/Sidebar/SidebarLinksGroup/SidebarLinksGroup.d.ts +2 -2
  88. package/cjs/Sidebar/SidebarNav.d.ts +2 -2
  89. package/cjs/Switch/Switch.d.ts +2 -2
  90. package/cjs/Switch/SwitchOption.d.ts +2 -2
  91. package/cjs/Switch/SwitchOption.js +3 -1
  92. package/cjs/Tables/DataTable/DataTable.d.ts +4 -2
  93. package/cjs/Tables/DataTable/DataTable.js +9 -4
  94. package/cjs/Tables/DataTable/components/Footer.d.ts +2 -2
  95. package/cjs/Tables/DataTable/components/Loader.d.ts +2 -2
  96. package/cjs/Tables/Table/Table.d.ts +2 -2
  97. package/cjs/Tables/Table/components/TableFooter.d.ts +2 -2
  98. package/cjs/Tabs/ContentTabs.d.ts +2 -2
  99. package/cjs/Tabs/LinkTabs.d.ts +2 -2
  100. package/cjs/Tabs/components/LinkTab.d.ts +2 -2
  101. package/cjs/TextArea/TextArea.tailwind.js +4 -1
  102. package/cjs/TextWrap/TextWrap.d.ts +2 -2
  103. package/cjs/Tooltip/OverflowTooltipWrapper.d.ts +4 -2
  104. package/cjs/Tooltip/OverflowTooltipWrapper.js +5 -2
  105. package/cjs/Tooltip/TooltipWrapper.d.ts +2 -3
  106. package/cjs/Tooltip/TooltipWrapper.js +4 -3
  107. package/cjs/Tooltip/types.d.ts +2 -2
  108. package/cjs/UserContent/UserContent.d.ts +2 -2
  109. package/cjs/styles/tailwind.config.js +3 -1
  110. package/cjs/utils/isReactText.d.ts +2 -0
  111. package/cjs/utils/isReactText.js +10 -0
  112. package/esm/AnnouncementBadge/AnnouncementBadge.d.ts +2 -2
  113. package/esm/AnnouncementBadge/AnnouncementBadge.js +7 -3
  114. package/esm/AutoComplete/AutoComplete.d.ts +1 -1
  115. package/esm/AutoComplete/AutoComplete.tailwind.js +1 -1
  116. package/esm/AutoComplete/components/AutoCompleteEmptyState.d.ts +3 -3
  117. package/esm/AutoComplete/components/DefaultOptionItem.d.ts +2 -2
  118. package/esm/Avatars/ApplicationAvatar.d.ts +2 -2
  119. package/esm/Avatars/UserAvatar.d.ts +2 -2
  120. package/esm/Badge/Badge.d.ts +3 -3
  121. package/esm/Badge/Badge.js +6 -3
  122. package/esm/Banners/Alert/Alert.d.ts +2 -2
  123. package/esm/Banners/BigBertha/BigBertha.d.ts +2 -2
  124. package/esm/Banners/Promote/Promote.d.ts +2 -2
  125. package/esm/Button/ButtonGroup.d.ts +2 -2
  126. package/esm/Button/PolymorphicButton.d.ts +2 -1
  127. package/esm/Button/PolymorphicButton.js +1 -0
  128. package/esm/Button/PolymorphicIconButton.d.ts +2 -1
  129. package/esm/Button/PolymorphicIconButton.js +1 -0
  130. package/esm/Button/index.d.ts +1 -1
  131. package/esm/Button/index.js +0 -1
  132. package/esm/Card/components/CardHeader.d.ts +2 -2
  133. package/esm/Card/components/CardTitle.d.ts +2 -2
  134. package/esm/ClickAwayContainer/ClickAwayContainer.d.ts +2 -2
  135. package/esm/DatePicker/DatePicker/DatePicker.d.ts +3 -3
  136. package/esm/DatePicker/DateRangePicker/DateRangePicker.d.ts +4 -3
  137. package/esm/DatePicker/DateRangePicker/DateRangePickerDisplay.d.ts +4 -4
  138. package/esm/DatePicker/DateRangePicker/dateRangePickerReducer.d.ts +1 -1
  139. package/esm/DatePicker/components/Calendar.d.ts +3 -3
  140. package/esm/DatePicker/components/Display.d.ts +2 -2
  141. package/esm/DatePicker/components/Footer.d.ts +2 -2
  142. package/esm/DatePicker/components/FooterActions.d.ts +3 -3
  143. package/esm/DatePicker/components/Modal.d.ts +2 -2
  144. package/esm/DatePicker/components/NavBar.d.ts +3 -3
  145. package/esm/DatePicker/components/SidePanel.d.ts +2 -2
  146. package/esm/Dropdown/Dropdown.d.ts +21 -36
  147. package/esm/Dropdown/DropdownButton.d.ts +3 -3
  148. package/esm/Dropdown/components/DropdownButtonItem.d.ts +3 -8
  149. package/esm/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItem.d.ts +2 -2
  150. package/esm/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsGroup.d.ts +2 -2
  151. package/esm/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsMultiGroup.d.ts +2 -2
  152. package/esm/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsSingleGroup.d.ts +2 -2
  153. package/esm/Dropdown/components/DropdownFooterItem.d.ts +2 -2
  154. package/esm/Dropdown/components/DropdownLinkItem.d.ts +3 -8
  155. package/esm/Dropdown/components/DropdownLinkItem.js +6 -1
  156. package/esm/Dropdown/components/DropdownRadioItem.d.ts +4 -9
  157. package/esm/Dropdown/components/DropdownTitle.d.ts +2 -2
  158. package/esm/Dropdown/components/DropdownToggleItem.d.ts +4 -9
  159. package/esm/Dropzone/Dropzone.d.ts +4 -3
  160. package/esm/Dropzone/Dropzone.js +17 -18
  161. package/esm/EmptyState/EmptyState.d.ts +2 -2
  162. package/esm/Field/Field.d.ts +3 -3
  163. package/esm/Flag/Flag.d.ts +2 -2
  164. package/esm/Flag/Flags.d.ts +2 -2
  165. package/esm/FlexGrid/FlexGrid.d.ts +2 -2
  166. package/esm/HelpUnderline/HelpUnderline.d.ts +3 -3
  167. package/esm/HelpUnderline/HelpUnderline.js +1 -1
  168. package/esm/Input/Input.tailwind.js +1 -1
  169. package/esm/Insert/Insert.d.ts +3 -3
  170. package/esm/KeyboardKey/KeyboardKey.d.ts +2 -2
  171. package/esm/Medallion/Medallion.d.ts +2 -2
  172. package/esm/Modal/Modal.d.ts +7 -5
  173. package/esm/Modal/components/ModalFooter.d.ts +2 -2
  174. package/esm/Modal/components/ModalSection.d.ts +2 -2
  175. package/esm/Pagination/CompactPagination/CompactPagination.d.ts +2 -2
  176. package/esm/Pagination/Pagination/Pagination.d.ts +2 -2
  177. package/esm/ProgressBar/ProgressBar.d.ts +2 -2
  178. package/esm/ProgressBar/ProgressBar.js +7 -3
  179. package/esm/ProgressSpinner/ProgressSpinner.d.ts +2 -2
  180. package/esm/RadioGroup/RadioGroup.d.ts +6 -6
  181. package/esm/RangeSlider/RangeSlider.d.ts +6 -4
  182. package/esm/RangeSlider/RangeSlider.js +14 -10
  183. package/esm/Satellite/Satellite.d.ts +2 -2
  184. package/esm/Satellite/Satellite.js +30 -15
  185. package/esm/Satellite/SatelliteContext.d.ts +1 -1
  186. package/esm/Satellite/useCreatePortal.d.ts +1 -1
  187. package/esm/ScrollIndicator/ScrollIndicator.d.ts +2 -2
  188. package/esm/Separator/Separator.d.ts +2 -2
  189. package/esm/Sidebar/Sidebar.d.ts +2 -2
  190. package/esm/Sidebar/SidebarButtonLink.d.ts +2 -2
  191. package/esm/Sidebar/SidebarButtonLink.js +2 -2
  192. package/esm/Sidebar/SidebarHeader.d.ts +2 -2
  193. package/esm/Sidebar/SidebarHeading.d.ts +2 -2
  194. package/esm/Sidebar/SidebarHeading.js +1 -1
  195. package/esm/Sidebar/SidebarLink.d.ts +2 -2
  196. package/esm/Sidebar/SidebarLinksGroup/ActiveLinkIndicator.d.ts +2 -2
  197. package/esm/Sidebar/SidebarLinksGroup/SidebarGroupLink.d.ts +2 -2
  198. package/esm/Sidebar/SidebarLinksGroup/SidebarLinksGroup.d.ts +2 -2
  199. package/esm/Sidebar/SidebarNav.d.ts +2 -2
  200. package/esm/Switch/Switch.d.ts +2 -2
  201. package/esm/Switch/SwitchOption.d.ts +2 -2
  202. package/esm/Switch/SwitchOption.js +3 -1
  203. package/esm/Tables/DataTable/DataTable.d.ts +4 -2
  204. package/esm/Tables/DataTable/DataTable.js +9 -4
  205. package/esm/Tables/DataTable/components/Footer.d.ts +2 -2
  206. package/esm/Tables/DataTable/components/Loader.d.ts +2 -2
  207. package/esm/Tables/Table/Table.d.ts +2 -2
  208. package/esm/Tables/Table/components/TableFooter.d.ts +2 -2
  209. package/esm/Tabs/ContentTabs.d.ts +2 -2
  210. package/esm/Tabs/LinkTabs.d.ts +2 -2
  211. package/esm/Tabs/components/LinkTab.d.ts +2 -2
  212. package/esm/TextArea/TextArea.tailwind.js +4 -1
  213. package/esm/TextWrap/TextWrap.d.ts +2 -2
  214. package/esm/Tooltip/OverflowTooltipWrapper.d.ts +4 -2
  215. package/esm/Tooltip/OverflowTooltipWrapper.js +5 -2
  216. package/esm/Tooltip/TooltipWrapper.d.ts +2 -3
  217. package/esm/Tooltip/TooltipWrapper.js +4 -3
  218. package/esm/Tooltip/types.d.ts +2 -2
  219. package/esm/UserContent/UserContent.d.ts +2 -2
  220. package/esm/styles/tailwind.config.js +3 -1
  221. package/esm/utils/isReactText.d.ts +2 -0
  222. package/esm/utils/isReactText.js +3 -0
  223. package/package.json +3 -2
  224. package/satellite.min.css +1 -1
@@ -1,5 +1,5 @@
1
1
  import type { TooltipContentProps } from "@radix-ui/react-tooltip";
2
- import type { ReactNode } from "react";
2
+ import type { ReactElement, ReactText } from "react";
3
3
  import type { TooltipVariant } from "./Tooltip";
4
4
  export interface TooltipWrapperBaseProps {
5
5
  /**
@@ -61,5 +61,5 @@ export interface TooltipWrapperBaseProps {
61
61
  * @default true
62
62
  */
63
63
  avoidCollisions?: boolean;
64
- children: ReactNode;
64
+ children: ReactElement | ReactText;
65
65
  }
@@ -1,8 +1,8 @@
1
- /// <reference types="react" />
1
+ import type { VFC } from "react";
2
2
  export interface UserContentProps {
3
3
  styled?: boolean;
4
4
  className?: string;
5
5
  content?: string;
6
6
  }
7
- export declare const UserContent: ({ className, content, styled }: UserContentProps) => JSX.Element | null;
7
+ export declare const UserContent: VFC<UserContentProps>;
8
8
  export default UserContent;
@@ -80,7 +80,9 @@ module.exports = {
80
80
  z200: "0px 0px 0px 1px ".concat(theme("colors.shadow.5"), ", 0px 4px 8px -2px ").concat(theme("colors.shadow.25")),
81
81
  z300: "0px 0px 0px 1px ".concat(theme("colors.shadow.5"), ", 0px 8px 16px -4px ").concat(theme("colors.shadow.25")),
82
82
  z400: "0px 0px 0px 1px ".concat(theme("colors.shadow.5"), ", 0px 12px 24px -6px ").concat(theme("colors.shadow.25")),
83
- z500: "0px 0px 0px 1px ".concat(theme("colors.shadow.5"), ", 0px 20px 32px -8px ").concat(theme("colors.shadow.25"))
83
+ z500: "0px 0px 0px 1px ".concat(theme("colors.shadow.5"), ", 0px 20px 32px -8px ").concat(theme("colors.shadow.25")),
84
+ field: "inset 0px 1px 4px 0px ".concat(rgba(colors.grey[500], 0.3)),
85
+ "field-focused": "0px 1px 0px 0px ".concat(theme("colors.shadow.5"))
84
86
  };
85
87
  },
86
88
  opacity: {
@@ -0,0 +1,2 @@
1
+ import type { ReactNode } from "react";
2
+ export declare const isReactText: (children: ReactNode) => children is string | number;
@@ -0,0 +1,10 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.isReactText = void 0;
7
+ var isReactText = function isReactText(children) {
8
+ return typeof children === "string" || typeof children === "number";
9
+ };
10
+ exports.isReactText = isReactText;
@@ -1,4 +1,4 @@
1
- import type { FunctionComponent, HTMLAttributes } from "react";
1
+ import type { HTMLAttributes } from "react";
2
2
  export declare type AnnouncementBadgeSizes = "default" | "small";
3
3
  export declare type AnnouncementBadgeTexts = "new" | "beta" | "internal" | "pilot";
4
4
  export declare type AnnouncementBadgeLocale = {
@@ -17,5 +17,5 @@ export interface AnnouncementBadgeProps extends HTMLAttributes<HTMLSpanElement>
17
17
  locale?: AnnouncementBadgeLocale;
18
18
  children?: never;
19
19
  }
20
- export declare const AnnouncementBadge: FunctionComponent<AnnouncementBadgeProps>;
20
+ export declare const AnnouncementBadge: import("react").ForwardRefExoticComponent<AnnouncementBadgeProps & import("react").RefAttributes<HTMLSpanElement>>;
21
21
  export default AnnouncementBadge;
@@ -6,6 +6,7 @@ var _templateObject, _templateObject2, _templateObject3, _templateObject4, _temp
6
6
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
7
7
  function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
8
8
  import cx from "clsx";
9
+ import { forwardRef } from "react";
9
10
  import { useLocale } from "../Satellite";
10
11
  import stl from "../styles/helpers/satellitePrefixer";
11
12
  import { jsx as _jsx } from "react/jsx-runtime";
@@ -20,7 +21,7 @@ var SIZE_CLASSNAMES = {
20
21
  "default": stl(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["display-body h-6 leading-md px-2"]))),
21
22
  small: stl(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["display-caption px-1"])))
22
23
  };
23
- export var AnnouncementBadge = function AnnouncementBadge(_ref) {
24
+ export var AnnouncementBadge = /*#__PURE__*/forwardRef(function (_ref, ref) {
24
25
  var _ref$size = _ref.size,
25
26
  size = _ref$size === void 0 ? "default" : _ref$size,
26
27
  _ref$text = _ref.text,
@@ -32,9 +33,12 @@ export var AnnouncementBadge = function AnnouncementBadge(_ref) {
32
33
  var contextLocale = useLocale("announcementBadge");
33
34
  var locale = _objectSpread(_objectSpread(_objectSpread({}, DEFAULT_LOCALE), contextLocale), propsLocale);
34
35
  var variant = typeof variantProp === "string" ? variantProp : text === "internal" ? "red" : "accent";
35
- return /*#__PURE__*/_jsx("span", _objectSpread(_objectSpread({}, props), {}, {
36
+ return /*#__PURE__*/_jsx("span", _objectSpread(_objectSpread({
37
+ ref: ref
38
+ }, props), {}, {
36
39
  className: cx(DEFAULT_CLASSNAME, variant === "red" ? stl(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["bg-red-600"]))) : stl(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["bg-accent-600"]))), SIZE_CLASSNAMES[size], className),
37
40
  children: locale[text]
38
41
  }));
39
- };
42
+ });
43
+ AnnouncementBadge.displayName = "AnnouncementBadge";
40
44
  export default AnnouncementBadge;
@@ -1,7 +1,7 @@
1
1
  import type { A11yStatusMessageOptions, ControllerStateAndHelpers } from "downshift";
2
2
  import { Component } from "react";
3
3
  import type { ChangeEvent, FocusEvent, KeyboardEvent, MouseEvent } from "react";
4
- import { FieldState } from "../Field/FieldStateContext";
4
+ import type { FieldState } from "../Field/FieldStateContext";
5
5
  import type { AutoCompleteLocale, AutoCompleteProps, Option, OptionItemProps } from "./types";
6
6
  interface State {
7
7
  inputFocused: boolean;
@@ -24,7 +24,7 @@ var autoCompletePlugin = plugin(function (_ref) {
24
24
  border: "1px solid ".concat(theme("colors.grey.500")),
25
25
  boxShadow: "inset 0px 1px 4px 0px ".concat(rgba(theme("colors.grey.500"), 0.3)),
26
26
  transition: "all 100ms ease-in-out",
27
- "&:not(.autocomplete-disabled):hover": {
27
+ "&:not(.autocomplete-disabled, .autocomplete-focused):hover": {
28
28
  borderColor: theme("colors.grey.600")
29
29
  },
30
30
  // Workaround for ie
@@ -1,5 +1,5 @@
1
- import type { ReactNode } from "react";
2
- import { MedallionVariant } from "../../Medallion";
1
+ import type { ReactNode, VFC } from "react";
2
+ import type { MedallionVariant } from "../../Medallion";
3
3
  import type { IconComponentType } from "../../types";
4
4
  export interface AutoCompleteEmptyStateProps {
5
5
  icon?: IconComponentType;
@@ -9,5 +9,5 @@ export interface AutoCompleteEmptyStateProps {
9
9
  /** Optional description to explain why the screen is empty or define next steps */
10
10
  description?: ReactNode;
11
11
  }
12
- export declare const AutoCompleteEmptyState: ({ icon, variant, title, description, }: AutoCompleteEmptyStateProps) => JSX.Element;
12
+ export declare const AutoCompleteEmptyState: VFC<AutoCompleteEmptyStateProps>;
13
13
  export default AutoCompleteEmptyState;
@@ -1,7 +1,7 @@
1
- /// <reference types="react" />
1
+ import type { VFC } from "react";
2
2
  import type { AutoCompleteLocale, OptionItemProps } from "../types";
3
3
  declare type DefaultOptionItemProps = OptionItemProps & {
4
4
  locale?: AutoCompleteLocale;
5
5
  };
6
- declare const DefaultOptionItem: ({ option, multiple, locale }: DefaultOptionItemProps) => JSX.Element;
6
+ declare const DefaultOptionItem: VFC<DefaultOptionItemProps>;
7
7
  export default DefaultOptionItem;
@@ -1,4 +1,4 @@
1
- /// <reference types="react" />
1
+ import type { VFC } from "react";
2
2
  import type { ApplicationAvatarSize, MinimalApplication } from "./types";
3
3
  export interface ApplicationAvatarProps {
4
4
  /** A minimal application object containing `applicationID` and `name`. */
@@ -9,5 +9,5 @@ export interface ApplicationAvatarProps {
9
9
  className?: string;
10
10
  }
11
11
  /** The `ApplicationAvatar` is used as a visual representation of an application. */
12
- export declare const ApplicationAvatar: ({ className, application, size }: ApplicationAvatarProps) => JSX.Element;
12
+ export declare const ApplicationAvatar: VFC<ApplicationAvatarProps>;
13
13
  export default ApplicationAvatar;
@@ -1,4 +1,4 @@
1
- /// <reference types="react" />
1
+ import type { VFC } from "react";
2
2
  import type { MinimalUser } from "./types";
3
3
  export declare type UserAvatarLocale = {
4
4
  fallbackText?: string;
@@ -16,5 +16,5 @@ export interface UserAvatarProps {
16
16
  locale?: UserAvatarLocale;
17
17
  }
18
18
  /** The `UserAvatar` is used as a visual representation of a user. */
19
- export declare const UserAvatar: ({ className, user, size, locale: propsLocale }: UserAvatarProps) => JSX.Element;
19
+ export declare const UserAvatar: VFC<UserAvatarProps>;
20
20
  export default UserAvatar;
@@ -1,8 +1,8 @@
1
- import type { FunctionComponent, HTMLAttributes, ReactNode } from "react";
1
+ import { type HTMLAttributes, type ReactNode } from "react";
2
2
  import type { AtLeastOne, ColorVariant, IconComponentType } from "../types";
3
3
  export declare type BadgeSizes = "small" | "medium" | "large";
4
4
  export declare type BadgeVariants = ColorVariant | "pink";
5
- interface BaseBadgeProps extends HTMLAttributes<HTMLDivElement> {
5
+ interface BaseBadgeProps extends HTMLAttributes<HTMLSpanElement> {
6
6
  /** @default "grey" */
7
7
  variant?: BadgeVariants;
8
8
  /** @default "default" */
@@ -31,5 +31,5 @@ export declare type BadgeProps = BaseBadgeProps & AtLeastOne<BadgeContentProps>;
31
31
  * - To indicate problem with an index
32
32
  * - To display numeric values for multiple items (similar to a "tag cloud")
33
33
  */
34
- export declare const Badge: FunctionComponent<BadgeProps>;
34
+ export declare const Badge: import("react").ForwardRefExoticComponent<BadgeProps & import("react").RefAttributes<HTMLSpanElement>>;
35
35
  export default Badge;
@@ -6,6 +6,7 @@ var _templateObject, _templateObject2, _templateObject3, _templateObject4, _temp
6
6
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
7
7
  function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
8
8
  import cx from "clsx";
9
+ import { forwardRef } from "react";
9
10
  import stl from "../styles/helpers/satellitePrefixer";
10
11
  import isRenderedChild from "../utils/isRenderedChild";
11
12
  import { jsx as _jsx } from "react/jsx-runtime";
@@ -41,7 +42,7 @@ var SIZE_CLASSNAMES = {
41
42
  * - To indicate problem with an index
42
43
  * - To display numeric values for multiple items (similar to a "tag cloud")
43
44
  */
44
- export var Badge = function Badge(_ref) {
45
+ export var Badge = /*#__PURE__*/forwardRef(function (_ref, ref) {
45
46
  var children = _ref.children,
46
47
  value = _ref.value,
47
48
  Icon = _ref.icon,
@@ -52,7 +53,8 @@ export var Badge = function Badge(_ref) {
52
53
  className = _ref.className,
53
54
  props = _objectWithoutProperties(_ref, _excluded);
54
55
  var badgeClassName = cx(BASE_CLASSNAMES, VARIANT_CLASSNAMES[variant], SIZE_CLASSNAMES[size], className);
55
- return /*#__PURE__*/_jsxs("div", _objectSpread(_objectSpread({}, props), {}, {
56
+ return /*#__PURE__*/_jsxs("span", _objectSpread(_objectSpread({}, props), {}, {
57
+ ref: ref,
56
58
  className: badgeClassName,
57
59
  children: [Icon && /*#__PURE__*/_jsx("span", {
58
60
  children: /*#__PURE__*/_jsx(Icon, {
@@ -65,5 +67,6 @@ export var Badge = function Badge(_ref) {
65
67
  children: value
66
68
  })]
67
69
  }));
68
- };
70
+ });
71
+ Badge.displayName = "Badge";
69
72
  export default Badge;
@@ -1,4 +1,4 @@
1
- import type { CSSProperties, FunctionComponent, ReactNode } from "react";
1
+ import type { CSSProperties, ReactNode, VFC } from "react";
2
2
  import type { ColorVariant, IconComponentType } from "../../types";
3
3
  export declare type AlertContextType = "page" | "section";
4
4
  export declare type AlertColorVariant = Exclude<ColorVariant, "blue">;
@@ -74,5 +74,5 @@ export interface AlertProps {
74
74
  * ## Accessibility
75
75
  * TODO
76
76
  */
77
- export declare const Alert: FunctionComponent<AlertProps>;
77
+ export declare const Alert: VFC<AlertProps>;
78
78
  export default Alert;
@@ -1,4 +1,4 @@
1
- import type { FC, ReactNode } from "react";
1
+ import type { ReactNode, VFC } from "react";
2
2
  import type { IconComponentType } from "../../types";
3
3
  export interface BigBerthaProps {
4
4
  icon?: IconComponentType;
@@ -37,5 +37,5 @@ export interface BigBerthaProps {
37
37
  * ## Accessibility
38
38
  * TODO
39
39
  */
40
- export declare const BigBertha: FC<BigBerthaProps>;
40
+ export declare const BigBertha: VFC<BigBerthaProps>;
41
41
  export default BigBertha;
@@ -1,4 +1,4 @@
1
- import type { FC, ReactNode } from "react";
1
+ import type { ReactNode, VFC } from "react";
2
2
  declare type PromoteVariants = "large" | "compact";
3
3
  interface CompactPromoteProps {
4
4
  variant?: Extract<PromoteVariants, "compact">;
@@ -53,5 +53,5 @@ export declare type PromoteProps = {
53
53
  * ## Accessibility
54
54
  * TODO
55
55
  */
56
- export declare const Promote: FC<PromoteProps>;
56
+ export declare const Promote: VFC<PromoteProps>;
57
57
  export default Promote;
@@ -1,4 +1,4 @@
1
- import type { FunctionComponent, ReactNode } from "react";
1
+ import type { ReactNode, VFC } from "react";
2
2
  export interface ButtonGroupProps {
3
3
  /**
4
4
  * Specify HTML element `ButtonGroup` should be presented as.
@@ -14,5 +14,5 @@ export interface ButtonGroupProps {
14
14
  * - Group buttons logically into sets based on usage and importance.
15
15
  * - Common placement of grouped buttons is the view switch (e.g. list vs grid view)
16
16
  */
17
- export declare const ButtonGroup: FunctionComponent<ButtonGroupProps>;
17
+ export declare const ButtonGroup: VFC<ButtonGroupProps>;
18
18
  export default ButtonGroup;
@@ -1,11 +1,12 @@
1
1
  import React from "react";
2
- import { ButtonBaseProps, PolymorphicComponentPropWithRef } from "./types";
2
+ import type { ButtonBaseProps, PolymorphicComponentPropWithRef } from "./types";
3
3
  export declare type PolymorphicButtonProps<C extends React.ElementType> = PolymorphicComponentPropWithRef<C, ButtonBaseProps>;
4
4
  declare type PolymorphicButtonComponent = (<C extends React.ElementType = "button">(props: PolymorphicButtonProps<C>) => React.ReactElement | null) & {
5
5
  displayName?: string;
6
6
  };
7
7
  /**
8
8
  * `PolymorphicButton` is intended for internal use
9
+ * @ignore
9
10
  */
10
11
  export declare const PolymorphicButton: PolymorphicButtonComponent;
11
12
  export {};
@@ -17,6 +17,7 @@ var BASE_CLASSNAMES = stl(_templateObject || (_templateObject = _taggedTemplateL
17
17
  var ICON_SIZE = 16;
18
18
  /**
19
19
  * `PolymorphicButton` is intended for internal use
20
+ * @ignore
20
21
  */
21
22
  export var PolymorphicButton = /*#__PURE__*/forwardRef(function (props, ref) {
22
23
  var _props$as = props.as,
@@ -1,7 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  import type { TooltipWrapperBaseProps } from "../Tooltip/types";
3
3
  import type { IconComponentType } from "../types";
4
- import { ButtonSize, ButtonVariant, PolymorphicComponentPropWithRef } from "./types";
4
+ import type { ButtonSize, ButtonVariant, PolymorphicComponentPropWithRef } from "./types";
5
5
  export interface IconButtonBaseProps {
6
6
  variant?: ButtonVariant;
7
7
  size?: ButtonSize;
@@ -19,6 +19,7 @@ declare type PolymorphicIconButtonComponent = (<C extends React.ElementType = "b
19
19
  };
20
20
  /**
21
21
  * `PolymorphicIconButton` is intended for internal use
22
+ * @ignore
22
23
  */
23
24
  export declare const PolymorphicIconButton: PolymorphicIconButtonComponent;
24
25
  export {};
@@ -26,6 +26,7 @@ var VARIANT_CLASSNAMES = _objectSpread(_objectSpread({}, BUTTON_VARIANT_CLASSNAM
26
26
  });
27
27
  /**
28
28
  * `PolymorphicIconButton` is intended for internal use
29
+ * @ignore
29
30
  */
30
31
  export var PolymorphicIconButton = /*#__PURE__*/forwardRef(function (props, ref) {
31
32
  var _props$as = props.as,
@@ -1,5 +1,5 @@
1
1
  export * from "./Button";
2
2
  export * from "./IconButton";
3
3
  export * from "./ButtonGroup";
4
- export { ButtonSize, ButtonVariant } from "./types";
4
+ export type { ButtonSize, ButtonVariant } from "./types";
5
5
  export { default } from "./Button";
@@ -1,5 +1,4 @@
1
1
  export * from "./Button";
2
2
  export * from "./IconButton";
3
3
  export * from "./ButtonGroup";
4
- export { ButtonSize, ButtonVariant } from "./types";
5
4
  export { default } from "./Button";
@@ -1,6 +1,6 @@
1
- import type { FunctionComponent, ReactNode } from "react";
1
+ import type { ReactNode, VFC } from "react";
2
2
  export declare type CardHeaderProps = JSX.IntrinsicElements["div"] & {
3
3
  children: ReactNode;
4
4
  };
5
- export declare const CardHeader: FunctionComponent<CardHeaderProps>;
5
+ export declare const CardHeader: VFC<CardHeaderProps>;
6
6
  export default CardHeader;
@@ -1,6 +1,6 @@
1
- import type { FunctionComponent, ReactNode } from "react";
1
+ import type { ReactNode, VFC } from "react";
2
2
  export declare type CardTitleProps = JSX.IntrinsicElements["h2"] & {
3
3
  children: ReactNode;
4
4
  };
5
- export declare const CardTitle: FunctionComponent<CardTitleProps>;
5
+ export declare const CardTitle: VFC<CardTitleProps>;
6
6
  export default CardTitle;
@@ -1,4 +1,4 @@
1
- import type { FC, ReactNode } from "react";
1
+ import type { ReactNode, VFC } from "react";
2
2
  interface ClickAwayContextType {
3
3
  registerElement(element: HTMLElement): void;
4
4
  unregisterElement(element: HTMLElement): void;
@@ -24,5 +24,5 @@ export interface ClickAwayContainerProps {
24
24
  * but it's not the case when using portals.
25
25
  * This component allows click-away functionality even when portals are involved.
26
26
  */
27
- export declare const ClickAwayContainer: FC<ClickAwayContainerProps>;
27
+ export declare const ClickAwayContainer: VFC<ClickAwayContainerProps>;
28
28
  export default ClickAwayContainer;
@@ -1,9 +1,9 @@
1
- import type { Dispatch, FunctionComponent, MouseEvent, ReactNode } from "react";
1
+ import type { Dispatch, MouseEvent, ReactNode, VFC } from "react";
2
2
  import type { CalendarProps } from "../components/Calendar";
3
3
  import type { DisplayProps } from "../components/Display";
4
4
  import type { FooterActionsProps } from "../components/FooterActions";
5
5
  import type { SharedDatePickerProps } from "../types";
6
- import { DatePickerReducerAction, DatePickerReducerState } from "./datePickerReducer";
6
+ import type { DatePickerReducerAction, DatePickerReducerState } from "./datePickerReducer";
7
7
  interface LeftFooterComponentArgs {
8
8
  state: DatePickerReducerState;
9
9
  dispatch: Dispatch<DatePickerReducerAction>;
@@ -30,5 +30,5 @@ export declare type DatePickerProps = {
30
30
  initialValue?: Date | null;
31
31
  buttonSize?: DisplayProps["size"];
32
32
  } & SharedDatePickerProps;
33
- declare const DatePicker: FunctionComponent<DatePickerProps>;
33
+ declare const DatePicker: VFC<DatePickerProps>;
34
34
  export default DatePicker;
@@ -1,8 +1,9 @@
1
- import type { Dispatch, FunctionComponent, ReactNode } from "react";
1
+ import type { Dispatch, ReactNode, VFC } from "react";
2
2
  import type { CalendarProps } from "../components/Calendar";
3
3
  import type { SharedDatePickerProps } from "../types";
4
4
  import type { DateRangePickerDisplayProps } from "./DateRangePickerDisplay";
5
- import { dateRangePickerReducer, DateRangePickerReducerAction, DateRangePickerReducerState } from "./dateRangePickerReducer";
5
+ import type { DateRangePickerReducerAction, DateRangePickerReducerState } from "./dateRangePickerReducer";
6
+ import { dateRangePickerReducer } from "./dateRangePickerReducer";
6
7
  import type { DateRangePickerTimeRange } from "./dateRangePickerTimeRange";
7
8
  interface LeftFooterComponentArgs {
8
9
  state: DateRangePickerReducerState;
@@ -30,5 +31,5 @@ export declare type DateRangePickerProps = {
30
31
  renderRightPanel?: (args: RightSidePanelComponentArgs) => ReactNode;
31
32
  buttonSize?: DateRangePickerDisplayProps["buttonSize"];
32
33
  } & SharedDatePickerProps;
33
- export declare const DateRangePicker: FunctionComponent<DateRangePickerProps>;
34
+ export declare const DateRangePicker: VFC<DateRangePickerProps>;
34
35
  export default DateRangePicker;
@@ -1,8 +1,8 @@
1
- import type { FunctionComponent } from "react";
1
+ import type { VFC } from "react";
2
2
  import type { WithRequiredProperty } from "../../types";
3
- import { DisplayProps } from "../components/Display";
3
+ import type { DisplayProps } from "../components/Display";
4
4
  import type { DatePickerLocale } from "../types";
5
- import { DateRangePickerTimeRange } from "./dateRangePickerTimeRange";
5
+ import type { DateRangePickerTimeRange } from "./dateRangePickerTimeRange";
6
6
  export interface DateRangePickerDisplayProps {
7
7
  id?: string;
8
8
  onClick: DisplayProps["onClick"];
@@ -10,5 +10,5 @@ export interface DateRangePickerDisplayProps {
10
10
  buttonSize?: DisplayProps["size"];
11
11
  locale: WithRequiredProperty<DatePickerLocale, "openButton">;
12
12
  }
13
- declare const DateRangePickerDisplay: FunctionComponent<DateRangePickerDisplayProps>;
13
+ declare const DateRangePickerDisplay: VFC<DateRangePickerDisplayProps>;
14
14
  export default DateRangePickerDisplay;
@@ -1,5 +1,5 @@
1
1
  import type { MouseEvent, Reducer } from "react";
2
- import { DateRangePickerCompleteTimeRange, DateRangePickerTimeRange } from "./dateRangePickerTimeRange";
2
+ import type { DateRangePickerCompleteTimeRange, DateRangePickerTimeRange } from "./dateRangePickerTimeRange";
3
3
  export declare enum DateRangePickerActionTypes {
4
4
  show = "show",
5
5
  dateSelect = "date select",
@@ -1,5 +1,5 @@
1
- import type { FunctionComponent } from "react";
2
- import { DayPickerDefaultProps, DayPickerRangeProps, DayPickerSingleProps } from "react-day-picker";
1
+ import type { VFC } from "react";
2
+ import type { DayPickerDefaultProps, DayPickerRangeProps, DayPickerSingleProps } from "react-day-picker";
3
3
  import type { WithRequiredProperty } from "../../types";
4
4
  import type { DatePickerLocale } from "../types";
5
5
  declare type ExcludedDayPickerProps = "captionElement" | "showOutsideDays" | "enableOutsideDaysClick" | "fixedWeeks" | "labels" | "navbarElement" | "onTodayButtonClick" | "pagedNavigation" | "renderDay" | "renderWeek" | "reverseMonths" | "showWeekNumber" | "showWeekDays" | "weekdayElement" | "weekdaysLong" | "weekdaysShort";
@@ -13,5 +13,5 @@ export declare type EditableYearProps = {
13
13
  export declare type CalendarProps = Omit<Omit<DayPickerSingleProps | DayPickerRangeProps | DayPickerDefaultProps, "locale">, ExcludedDayPickerProps> & EditableYearProps & {
14
14
  locale: WithRequiredProperty<DatePickerLocale, "nextMonth" | "previousMonth">;
15
15
  };
16
- declare const Calendar: FunctionComponent<CalendarProps>;
16
+ declare const Calendar: VFC<CalendarProps>;
17
17
  export default Calendar;
@@ -1,4 +1,4 @@
1
- import type { FunctionComponent, ReactNode } from "react";
1
+ import type { ReactNode, VFC } from "react";
2
2
  import type { ButtonProps, ButtonSize } from "../../Button";
3
3
  export interface DisplayProps {
4
4
  id?: string;
@@ -6,5 +6,5 @@ export interface DisplayProps {
6
6
  children: ReactNode;
7
7
  size?: ButtonSize;
8
8
  }
9
- declare const Display: FunctionComponent<DisplayProps>;
9
+ declare const Display: VFC<DisplayProps>;
10
10
  export default Display;
@@ -1,6 +1,6 @@
1
- import type { FunctionComponent, ReactNode } from "react";
1
+ import type { ReactNode, VFC } from "react";
2
2
  export declare type FooterProps = {
3
3
  children: ReactNode;
4
4
  };
5
- declare const Footer: FunctionComponent<FooterProps>;
5
+ declare const Footer: VFC<FooterProps>;
6
6
  export default Footer;
@@ -1,5 +1,5 @@
1
- import type { FunctionComponent } from "react";
2
- import { ButtonProps } from "../../Button";
1
+ import type { VFC } from "react";
2
+ import type { ButtonProps } from "../../Button";
3
3
  import type { WithRequiredProperty } from "../../types";
4
4
  import type { DatePickerLocale } from "../types";
5
5
  export interface FooterActionsProps {
@@ -8,5 +8,5 @@ export interface FooterActionsProps {
8
8
  disableApply: boolean;
9
9
  locale: WithRequiredProperty<DatePickerLocale, "cancel" | "apply">;
10
10
  }
11
- declare const FooterActions: FunctionComponent<FooterActionsProps>;
11
+ declare const FooterActions: VFC<FooterActionsProps>;
12
12
  export default FooterActions;
@@ -1,5 +1,5 @@
1
1
  import type { Placement, StrictModifiers } from "@popperjs/core";
2
- import type { FC, ReactNode } from "react";
2
+ import type { ReactNode, VFC } from "react";
3
3
  import type { StrictModifier } from "react-popper";
4
4
  import type { ClickAwayContainerProps } from "../../ClickAwayContainer";
5
5
  export interface ModalProps {
@@ -12,5 +12,5 @@ export interface ModalProps {
12
12
  onClickAway?: ClickAwayContainerProps["onClickAway"];
13
13
  }
14
14
  export declare const DEFAULT_DATE_PICKER_MODAL_POPPER_MODIFIERS: StrictModifier[];
15
- declare const Modal: FC<ModalProps>;
15
+ declare const Modal: VFC<ModalProps>;
16
16
  export default Modal;
@@ -1,10 +1,10 @@
1
- import type { FunctionComponent } from "react";
2
- import { CaptionProps } from "react-day-picker";
1
+ import type { VFC } from "react";
2
+ import type { CaptionProps } from "react-day-picker";
3
3
  import type { WithRequiredProperty } from "../../types";
4
4
  import type { DatePickerLocale } from "../types";
5
5
  import type { EditableYearProps } from "./Calendar";
6
6
  export declare type NavBarProps = CaptionProps & EditableYearProps & {
7
7
  locale: WithRequiredProperty<DatePickerLocale, "nextMonth" | "previousMonth">;
8
8
  };
9
- declare const NavBar: FunctionComponent<NavBarProps>;
9
+ declare const NavBar: VFC<NavBarProps>;
10
10
  export default NavBar;
@@ -1,6 +1,6 @@
1
- import type { FunctionComponent, ReactNode } from "react";
1
+ import type { ReactNode, VFC } from "react";
2
2
  export declare type SidePanelProps = {
3
3
  children: ReactNode;
4
4
  };
5
- declare const SidePanel: FunctionComponent<SidePanelProps>;
5
+ declare const SidePanel: VFC<SidePanelProps>;
6
6
  export default SidePanel;
@@ -1,6 +1,14 @@
1
1
  import type { StrictModifiers } from "@popperjs/core";
2
- import type { ReactNode } from "react";
3
- import { StrictModifier } from "react-popper";
2
+ import type { ReactNode, VFC } from "react";
3
+ import type { StrictModifier } from "react-popper";
4
+ import DropdownButtonItem from "./components/DropdownButtonItem";
5
+ import { DropdownCollapsibleItem } from "./components/DropdownCollapsibleItem";
6
+ import DropdownDivider from "./components/DropdownDivider";
7
+ import DropdownFooterItem from "./components/DropdownFooterItem";
8
+ import DropdownLinkItem from "./components/DropdownLinkItem";
9
+ import DropdownRadioItem from "./components/DropdownRadioItem";
10
+ import DropdownTitle from "./components/DropdownTitle";
11
+ import DropdownToggleItem from "./components/DropdownToggleItem";
4
12
  export interface RenderTargetParams {
5
13
  toggle: (open?: boolean) => any;
6
14
  isShowingMenu: boolean;
@@ -16,6 +24,16 @@ export interface DropdownProps {
16
24
  renderFooter?: (params: RenderTargetParams) => ReactNode;
17
25
  children?: ReactNode;
18
26
  }
27
+ declare type DropdownSubComponents = {
28
+ ButtonItem: typeof DropdownButtonItem;
29
+ LinkItem: typeof DropdownLinkItem;
30
+ RadioItem: typeof DropdownRadioItem;
31
+ ToggleItem: typeof DropdownToggleItem;
32
+ CollapsibleItem: typeof DropdownCollapsibleItem;
33
+ FooterItem: typeof DropdownFooterItem;
34
+ Divider: typeof DropdownDivider;
35
+ Title: typeof DropdownTitle;
36
+ };
19
37
  export declare const DEFAULT_DROPDOWN_POPPER_MODIFIERS: StrictModifier[];
20
38
  /**
21
39
  * ## Best practices
@@ -27,38 +45,5 @@ export declare const DEFAULT_DROPDOWN_POPPER_MODIFIERS: StrictModifier[];
27
45
  * - Clearly label options based on what each one will do
28
46
  * - Make sure the most common options are listed. These can be grouped into sub-categories under headings
29
47
  */
30
- export declare const Dropdown: {
31
- ({ placement, menuClassName, modifiers, renderTarget, renderFooter, children, }: DropdownProps): JSX.Element;
32
- ButtonItem: {
33
- (props: import("./components/DropdownButtonItem").DropdownButtonItemProps): JSX.Element;
34
- defaultProps: {
35
- toggle: boolean;
36
- };
37
- };
38
- LinkItem: {
39
- (props: import("./components/DropdownLinkItem").DropdownLinkItemProps): JSX.Element;
40
- defaultProps: {
41
- toggle: boolean;
42
- };
43
- };
44
- RadioItem: {
45
- (props: import("./components/DropdownRadioItem").DropdownRadioItemProps): JSX.Element;
46
- defaultProps: {
47
- toggle: boolean;
48
- };
49
- };
50
- ToggleItem: {
51
- (props: import("./components/DropdownToggleItem").DropdownToggleItemProps): JSX.Element;
52
- defaultProps: {
53
- toggle: boolean;
54
- };
55
- };
56
- CollapsibleItem: import("react").FC<import("./components/DropdownCollapsibleItem").DropdownCollapsibleItemProps>;
57
- FooterItem: ({ children, className, ...props }: {
58
- className?: string | undefined;
59
- children: ReactNode;
60
- }) => JSX.Element | null;
61
- Divider: () => JSX.Element;
62
- Title: import("react").FunctionComponent<import("./components/DropdownTitle").DropdownTitleProps>;
63
- };
48
+ export declare const Dropdown: VFC<DropdownProps> & DropdownSubComponents;
64
49
  export default Dropdown;