fix(TreeSelect): placehold slot invalid (#7545)

This commit is contained in:
selicens 2024-04-30 19:11:08 +08:00 committed by GitHub
parent 9a45b35511
commit e01f26c541
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -236,6 +236,7 @@ const TreeSelect = defineComponent({
switcherIcon = slots.switcherIcon?.(),
fieldNames = props.replaceFields,
id = formItemContext.id.value,
placeholder = slots.placeholder?.(),
} = props;
const { isFormItemInput, hasFeedback, feedbackIcon } = formItemInputContext;
// ===================== Icons =====================
@ -342,6 +343,7 @@ const TreeSelect = defineComponent({
maxTagPlaceholder={props.maxTagPlaceholder || slots.maxTagPlaceholder}
placement={placement.value}
showArrow={hasFeedback || showArrow}
placeholder={placeholder}
/>,
),
);