mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
fix(Field): adjust textarea size when focus/blur (#9718)
This commit is contained in:
parent
24f8919d58
commit
03b33985cb
@ -347,6 +347,8 @@ export default createComponent({
|
|||||||
onFocus(event) {
|
onFocus(event) {
|
||||||
this.focused = true;
|
this.focused = true;
|
||||||
this.$emit('focus', event);
|
this.$emit('focus', event);
|
||||||
|
// https://github.com/youzan/vant/issues/9715
|
||||||
|
this.$nextTick(this.adjustSize);
|
||||||
|
|
||||||
// readonly not work in legacy mobile safari
|
// readonly not work in legacy mobile safari
|
||||||
/* istanbul ignore if */
|
/* istanbul ignore if */
|
||||||
@ -361,6 +363,7 @@ export default createComponent({
|
|||||||
this.updateValue(this.value, 'onBlur');
|
this.updateValue(this.value, 'onBlur');
|
||||||
this.$emit('blur', event);
|
this.$emit('blur', event);
|
||||||
this.validateWithTrigger('onBlur');
|
this.validateWithTrigger('onBlur');
|
||||||
|
this.$nextTick(this.adjustSize);
|
||||||
resetScroll();
|
resetScroll();
|
||||||
},
|
},
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user