From 38c5d1d7e959be78eee1d2fba7082734f7f7ec28 Mon Sep 17 00:00:00 2001 From: KumJungMin <37934668+KumJungMin@users.noreply.github.com> Date: Sat, 13 Jul 2024 20:36:28 +0900 Subject: [PATCH] fix: hide clear button when options is empty (#6880) --- components/lib/dropdown/Dropdown.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/lib/dropdown/Dropdown.js b/components/lib/dropdown/Dropdown.js index 1980f30988..587eae7c65 100644 --- a/components/lib/dropdown/Dropdown.js +++ b/components/lib/dropdown/Dropdown.js @@ -1138,7 +1138,7 @@ export const Dropdown = React.memo( }; const createClearIcon = () => { - if (props.value != null && props.showClear && !props.disabled) { + if (props.value != null && props.showClear && !props.disabled && !ObjectUtils.isEmpty(props.options)) { const clearIconProps = mergeProps( { className: cx('clearIcon'),