From b5ab14df8d516ee82d7ca5e0dfdc3ee2c8ada4f1 Mon Sep 17 00:00:00 2001 From: tangjinzhou <415800467@qq.com> Date: Sat, 17 Jul 2021 21:19:10 +0800 Subject: [PATCH] fix: formitem error when use native tag #4383 close #4383 --- components/form/FormItem.tsx | 2 +- v2-doc | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/components/form/FormItem.tsx b/components/form/FormItem.tsx index 986ba8699..af687fc34 100644 --- a/components/form/FormItem.tsx +++ b/components/form/FormItem.tsx @@ -306,7 +306,7 @@ export default defineComponent({ const children = flattenChildren(slots.default?.()); let firstChildren = children[0]; if (fieldName.value && props.autoLink && isValidElement(firstChildren)) { - const originalEvents = firstChildren.props; + const originalEvents = firstChildren.props || {}; const originalBlur = originalEvents.onBlur; const originalChange = originalEvents.onChange; firstChildren = cloneElement(firstChildren, { diff --git a/v2-doc b/v2-doc index 57c08127b..fc73e64bc 160000 --- a/v2-doc +++ b/v2-doc @@ -1 +1 @@ -Subproject commit 57c08127bf0e3e826b03f845df3e1332820964e5 +Subproject commit fc73e64bcdf41be854c2f7a907c05b056ad652ab