diff --git a/components/input/Input.jsx b/components/input/Input.jsx
index b598cafbc..24ddf1fe0 100644
--- a/components/input/Input.jsx
+++ b/components/input/Input.jsx
@@ -124,6 +124,7 @@ export default {
},
handleChange(e) {
+ if (e.target.composing) return;
this.setValue(e.target.value, e);
},
@@ -237,6 +238,7 @@ export default {
]);
const { stateValue, getInputClassName, handleKeyDown, handleChange, $listeners } = this;
const inputProps = {
+ directives: [{ name: 'ant-input' }],
domProps: {
value: fixControlledValue(stateValue),
},
@@ -251,7 +253,6 @@ export default {
ref: 'input',
key: 'ant-input',
};
- inputProps.directives = [{ name: 'ant-input' }];
return this.renderLabeledIcon(prefixCls, );
},
},
@@ -263,8 +264,9 @@ export default {
attrs: this.$attrs,
on: {
...$listeners,
- change: this.handleChange,
+ input: this.handleChange,
keydown: this.handleKeyDown,
+ change: noop,
},
directives: [
{
diff --git a/components/input/TextArea.jsx b/components/input/TextArea.jsx
index 1b42e399c..4ff2c40d7 100644
--- a/components/input/TextArea.jsx
+++ b/components/input/TextArea.jsx
@@ -116,6 +116,7 @@ export default {
},
handleTextareaChange(e) {
+ if (e.target.composing) return;
if (!hasProp(this, 'value')) {
this.stateValue = e.target.value;
this.resizeTextarea();
@@ -163,6 +164,7 @@ export default {
});
const textareaProps = {
+ directives: [{ name: 'ant-input' }],
attrs: { ...otherProps, ...$attrs },
on: {
...$listeners,
@@ -171,9 +173,6 @@ export default {
change: noop,
},
};
- if ($listeners['change.value']) {
- textareaProps.directives = [{ name: 'ant-input' }];
- }
return (
{inputIcon || }
{this.renderClearButton()}
diff --git a/components/vc-tree-select/src/Select.jsx b/components/vc-tree-select/src/Select.jsx
index f1d2ada89..f513e2fa8 100644
--- a/components/vc-tree-select/src/Select.jsx
+++ b/components/vc-tree-select/src/Select.jsx
@@ -789,7 +789,9 @@ const Select = {
this.setOpenState(open, true);
},
- onSearchInputChange({ target: { value } }) {
+ onSearchInputChange(event) {
+ if (event.target.composing) return;
+ const value = event.target.value;
const { _treeNodes: treeNodes, _valueEntities: valueEntities } = this.$data;
const { filterTreeNode, treeNodeFilterProp } = this.$props;
this.__emit('update:searchValue', value);