mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
fix(Field): should emit blur event when readonly (#11699)
This commit is contained in:
parent
d883591b91
commit
07c0e3e9da
@ -397,13 +397,14 @@ export default defineComponent({
|
||||
};
|
||||
|
||||
const onBlur = (event: Event) => {
|
||||
state.focused = false;
|
||||
updateValue(getModelValue(), 'onBlur');
|
||||
emit('blur', event);
|
||||
|
||||
if (getProp('readonly')) {
|
||||
return;
|
||||
}
|
||||
|
||||
state.focused = false;
|
||||
updateValue(getModelValue(), 'onBlur');
|
||||
emit('blur', event);
|
||||
validateWithTrigger('onBlur');
|
||||
nextTick(adjustTextareaSize);
|
||||
resetScroll();
|
||||
|
Loading…
x
Reference in New Issue
Block a user