mirror of
https://github.com/zhigang1992/react-native-paper.git
synced 2026-06-13 09:34:40 +08:00
40 lines
1.0 KiB
TypeScript
40 lines
1.0 KiB
TypeScript
import * as React from 'react';
|
|
import { TextInputProps as NativeTextInputProps } from 'react-native';
|
|
import { ThemeShape } from '../types';
|
|
|
|
export interface TextInputProps extends NativeTextInputProps {
|
|
mode?: 'flat' | 'outlined';
|
|
disabled?: boolean;
|
|
label?: string;
|
|
placeholder?: string;
|
|
error?: boolean;
|
|
onChangeText?: (text: string) => void;
|
|
underlineColor?: string;
|
|
multiline?: boolean;
|
|
numberOfLines?: number;
|
|
onFocus?: () => any;
|
|
onBlur?: () => any;
|
|
render?: (props: RenderProps) => React.ReactNode;
|
|
value?: string;
|
|
style?: any;
|
|
theme?: ThemeShape;
|
|
}
|
|
|
|
export interface RenderProps extends NativeTextInputProps {
|
|
ref: (ref: any) => void;
|
|
onChangeText: (text: string) => void;
|
|
placeholder?: string;
|
|
placeholderTextColor: string;
|
|
editable?: boolean;
|
|
selectionColor: string;
|
|
onFocus: () => any;
|
|
onBlur: () => any;
|
|
underlineColorAndroid: string;
|
|
style: any;
|
|
multiline?: boolean;
|
|
numberOfLines?: number;
|
|
value?: string;
|
|
}
|
|
|
|
export declare class TextInput extends React.Component<TextInputProps> {}
|