secondStep: PropTypes.number,
focusOnOpen: PropTypes.bool,
onKeyDown: PropTypes.func,
+ autoFocus: PropTypes.bool,
};
static defaultProps = {
this.picker.focus();
}
+ blur() {
+ this.picker.blur();
+ }
+
render() {
const {
prefixCls, placeholder, placement, align,
disabled, transitionName, style, className, getPopupContainer, name, autoComplete,
- onFocus, onBlur,
+ onFocus, onBlur, autoFocus,
} = this.props;
const { open, value } = this.state;
const popupClassName = this.getPopupClassName();
type="text"
placeholder={placeholder}
name={name}
- readOnly
onKeyDown={this.onKeyDown}
- disabled={disabled} value={value && value.format(this.getFormat()) || ''}
+ disabled={disabled}
+ value={value && value.format(this.getFormat()) || ''}
autoComplete={autoComplete}
onFocus={onFocus}
onBlur={onBlur}
+ autoFocus={autoFocus}
/>
<span className={`${prefixCls}-icon`}/>
</span>