@nulogy/components 14.7.1 → 14.7.2
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.
|
@@ -1,13 +1,16 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { ComponentVariant } from "../NDSProvider/ComponentVariantContext";
|
|
3
3
|
import { StyledProps } from "../StyledProps";
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
4
|
+
type DropdownMenuRenderProps = {
|
|
5
|
+
closeMenu: (e: React.MouseEvent) => void;
|
|
6
|
+
openMenu: (e: React.MouseEvent) => void;
|
|
7
|
+
};
|
|
8
|
+
interface DropdownMenuProps extends StyledProps {
|
|
9
|
+
children?: React.ReactNode | ((props: DropdownMenuRenderProps) => React.ReactElement);
|
|
7
10
|
variant?: ComponentVariant;
|
|
8
11
|
id?: string;
|
|
9
12
|
disabled?: boolean;
|
|
10
|
-
trigger?: () => React.
|
|
13
|
+
trigger?: () => React.ReactElement;
|
|
11
14
|
backgroundColor?: string;
|
|
12
15
|
showArrow?: boolean;
|
|
13
16
|
placement?: "top" | "top-start" | "top-end" | "bottom" | "bottom-start" | "bottom-end" | "left" | "left-start" | "left-end" | "right" | "right-start" | "right-end";
|
|
@@ -18,5 +21,7 @@ declare const DropdownMenu: React.ForwardRefExoticComponent<{
|
|
|
18
21
|
openAriaLabel?: string;
|
|
19
22
|
closeAriaLabel?: string;
|
|
20
23
|
openOnHover?: boolean;
|
|
21
|
-
|
|
24
|
+
className?: string;
|
|
25
|
+
}
|
|
26
|
+
declare const DropdownMenu: React.ForwardRefExoticComponent<DropdownMenuProps & React.RefAttributes<React.Ref<unknown>>>;
|
|
22
27
|
export default DropdownMenu;
|