Browse Source

`onKeyDown` bug fix (#5766)

+ close #5487
pull/5836/head
陆离 8 years ago
committed by ddcat1115
parent
commit
b694608af4
  1. 9
      components/auto-complete/index.tsx

9
components/auto-complete/index.tsx

@ -52,7 +52,14 @@ export default class AutoComplete extends React.Component<AutoCompleteProps, any
const element = children && React.isValidElement(children) && children.type !== Option ?
React.Children.only(this.props.children) :
<Input/>;
return <InputElement className="ant-input">{element}</InputElement>;
return (
<InputElement
{...element.props}
className={classNames('ant-input', element.props.className)}
>
{element}
</InputElement>
);
}
render() {

Loading…
Cancel
Save