fix: the disabled state should not trigger focus (#18108)

This commit is contained in:
btea
2024-08-31 19:48:48 +08:00
committed by GitHub
parent 4f380a6911
commit d7e5f193cd
6 changed files with 20 additions and 1 deletions

View File

@ -263,6 +263,9 @@ const _ref = computed(() => input.value || textarea.value)
const { wrapperRef, isFocused, handleFocus, handleBlur } = useFocusController(
_ref,
{
beforeFocus() {
return inputDisabled.value
},
afterBlur() {
if (props.validateEvent) {
elFormItem?.validate?.('blur').catch((err) => debugWarn(err))