fix Input type error (#9046)

pull/9049/head
曾凯 7 years ago committed by 偏右
parent aa9e335145
commit d868c5a58e

@ -28,7 +28,7 @@ export interface InputProps extends AbstractInputProps {
id?: number | string;
name?: string;
size?: 'large' | 'default' | 'small';
maxLength?: number;
maxLength?: number | string;
disabled?: boolean;
readOnly?: boolean;
addonBefore?: React.ReactNode;
@ -65,7 +65,10 @@ export default class Input extends React.Component<InputProps, any> {
PropTypes.number,
]),
size: PropTypes.oneOf(['small', 'default', 'large']),
maxLength: PropTypes.string,
maxLength: PropTypes.oneOfType([
PropTypes.string,
PropTypes.number,
]),
disabled: PropTypes.bool,
value: PropTypes.any,
defaultValue: PropTypes.any,

Loading…
Cancel
Save