diff --git a/packages/core/client/src/schema-component/antd/select/Select.tsx b/packages/core/client/src/schema-component/antd/select/Select.tsx index a3e11795e..9dd501881 100644 --- a/packages/core/client/src/schema-component/antd/select/Select.tsx +++ b/packages/core/client/src/schema-component/antd/select/Select.tsx @@ -65,6 +65,8 @@ const ObjectSelect = (props: Props) => { ); }; +const filterOption = (input, option) => (option?.label ?? '').toLowerCase().includes((input || '').toLowerCase()); + export const Select = connect( (props: Props) => { const { objectValue, ...others } = props; @@ -74,10 +76,7 @@ export const Select = connect( return ( (option?.label ?? '').includes(input)} - filterSort={(optionA, optionB) => - (optionA?.label ?? '').toLowerCase().localeCompare((optionB?.label ?? '').toLowerCase()) - } + filterOption={filterOption} allowClear {...others} onChange={(changed) => {