mui-simple
Version:
Override mui-v7 components to simplify usage
41 lines • 1.36 kB
TypeScript
export declare function useChildrenComponentBinding({ boundChildrenId, boundChildrenIndex, children, setAnchorEl, ref, setOpenControlled, showOnHover, }: {
open?: boolean;
boundChildrenId?: string;
boundChildrenIndex?: number | boolean;
children?: any;
setAnchorEl?: (event: any) => void;
anchorElementRef?: any;
ref?: any;
setOpenControlled?: (event: any, open?: boolean) => void;
showOnHover?: boolean;
}): any[];
interface AnchorPositionMouse {
left: number;
top: number;
}
interface AnchorPositionRelative {
vertical: 'top' | 'center' | 'bottom';
horizontal: 'left' | 'center' | 'right';
}
interface UseAnchorProps {
contextMenu?: any;
anchorElementRef?: any;
anchorPosition?: Partial<AnchorPositionRelative | AnchorPositionMouse>;
}
interface UseAnchorPropsResponse {
setAnchorEl: (value: any) => void;
anchorProps: object | {
anchorReference: 'anchorPosition';
anchorPosition: {
top: number;
left: number;
};
} | {
anchorEl: any;
transformOrigin: AnchorPositionRelative;
anchorPosition: AnchorPositionRelative;
};
}
export declare function useAnchorProps({ contextMenu, anchorElementRef, anchorPosition, }: UseAnchorProps): UseAnchorPropsResponse;
export {};
//# sourceMappingURL=Menu.hooks.d.ts.map