UNPKG

958 BTypeScriptView Raw
1import { MouseEventHandler, PureComponent, ReactElement } from 'react';
2import PropTypes from 'prop-types';
3export declare type Size = {
4 x: number;
5 y: number;
6 width: number;
7 height: number;
8 position: string;
9};
10export interface MouseDownProps {
11 children: (child: ReactElement<any>, size?: Size) => ReactElement<any>;
12 rippleChild: ReactElement<any>;
13}
14export interface MouseDownState {
15 size?: Size;
16}
17export default class MouseDown extends PureComponent<MouseDownProps> {
18 static displayName: string;
19 static propTypes: {
20 rippleChild: PropTypes.Requireable<PropTypes.ReactNodeLike>;
21 };
22 state: MouseDownState;
23 render(): ReactElement<any, string | ((props: any) => ReactElement<any, string | any | (new (props: any) => import("react").Component<any, any, any>)> | null) | (new (props: any) => import("react").Component<any, any, any>)>;
24 show: MouseEventHandler<HTMLElement>;
25 hide: () => void;
26}