UNPKG

@grafana/ui

Version:
28 lines (27 loc) 728 B
import { PureComponent } from 'react'; export interface Props { /** * When clicking outside of current element */ onClick: () => void; /** * Runs the 'onClick' function when pressing a key outside of the current element. Defaults to true. */ includeButtonPress: boolean; } interface State { hasEventListener: boolean; } export declare class ClickOutsideWrapper extends PureComponent<Props, State> { static defaultProps: { includeButtonPress: boolean; }; state: { hasEventListener: boolean; }; componentDidMount(): void; componentWillUnmount(): void; onOutsideClick: (event: any) => void; render(): import("react").ReactNode; } export {};