UNPKG

1.61 kBTypeScriptView Raw
1import * as React from 'react';
2import { IPickerProps } from './PickerTypes';
3export interface IItemProps {
4 className?: string;
5 value: any;
6 children?: React.ReactNode;
7}
8export default function (ComposedComponent: any): {
9 new (props?: IPickerProps, context?: any): {
10 select: (value: any, itemHeight: any, scrollTo: any) => void;
11 selectByIndex(index: any, itemHeight: any, zscrollTo: any): void;
12 computeChildIndex(top: any, itemHeight: any, childrenLength: any): number;
13 doScrollingComplete: (top: any, itemHeight: any, fireValueChange: any) => void;
14 render(): JSX.Element;
15 setState<K extends string | number | symbol>(state: any, callback?: () => any): void;
16 forceUpdate(callBack?: () => any): void;
17 props: Readonly<{
18 children?: React.ReactNode;
19 }> & Readonly<IPickerProps>;
20 state: Readonly<any>;
21 context: any;
22 refs: {
23 [key: string]: React.ReactInstance;
24 };
25 componentWillMount?(): void;
26 componentDidMount?(): void;
27 componentWillReceiveProps?(nextProps: Readonly<IPickerProps>, nextContext: any): void;
28 shouldComponentUpdate?(nextProps: Readonly<IPickerProps>, nextState: Readonly<any>, nextContext: any): boolean;
29 componentWillUpdate?(nextProps: Readonly<IPickerProps>, nextState: Readonly<any>, nextContext: any): void;
30 componentDidUpdate?(prevProps: Readonly<IPickerProps>, prevState: Readonly<any>, prevContext: any): void;
31 componentWillUnmount?(): void;
32 };
33 Item: (_props: IItemProps) => any;
34};