diff --git a/components/input/ClearableLabeledInput.jsx b/components/input/ClearableLabeledInput.jsx index a478b61ef..d27caf6d8 100644 --- a/components/input/ClearableLabeledInput.jsx +++ b/components/input/ClearableLabeledInput.jsx @@ -93,6 +93,7 @@ const ClearableLabeledInput = { [`${prefixCls}-affix-wrapper-input-with-clear-btn`]: props.suffix && props.allowClear && this.$props.value, }); + return ( {prefix} diff --git a/components/input/Input.jsx b/components/input/Input.jsx index f852224f5..2c5dab374 100644 --- a/components/input/Input.jsx +++ b/components/input/Input.jsx @@ -136,6 +136,7 @@ export default { 'lazy', 'size', 'inputType', + 'className', ]); const { stateValue, handleKeyDown, handleChange, size, disabled } = this; const inputProps = { diff --git a/components/input/Search.jsx b/components/input/Search.jsx index 34d4ac6dd..4df2a5e4e 100644 --- a/components/input/Search.jsx +++ b/components/input/Search.jsx @@ -170,9 +170,9 @@ export default { prefix: getComponentFromProp(this, 'prefix'), addonAfter: this.renderAddonAfter(prefixCls), addonBefore, + className: inputClassName, }, attrs: this.$attrs, - class: inputClassName, ref: 'input', on: { pressEnter: this.onSearch, diff --git a/components/input/inputProps.js b/components/input/inputProps.js index e0cefee3e..0158a09ed 100644 --- a/components/input/inputProps.js +++ b/components/input/inputProps.js @@ -32,4 +32,5 @@ export default { }, maxLength: PropTypes.number, loading: PropTypes.bool, + className: PropTypes.string, };