From c1c91095b8fb8401736b89ad917de9322ec5bccd Mon Sep 17 00:00:00 2001 From: Junyi Date: Sat, 2 Dec 2023 14:57:56 +0800 Subject: [PATCH] fix(client): allow match query case insensitive (#3127) --- .../antd/collection-select/CollectionSelect.tsx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/core/client/src/schema-component/antd/collection-select/CollectionSelect.tsx b/packages/core/client/src/schema-component/antd/collection-select/CollectionSelect.tsx index 968d59a96..84cdc4cc6 100644 --- a/packages/core/client/src/schema-component/antd/collection-select/CollectionSelect.tsx +++ b/packages/core/client/src/schema-component/antd/collection-select/CollectionSelect.tsx @@ -52,7 +52,10 @@ export const CollectionSelect = connect( popupMatchSelectWidth={false} {...others} showSearch - filterOption={(input, option) => (option?.label ?? '').includes(input)} + filterOption={(input, option) => + (option?.label.toLowerCase() ?? '').includes(input.toLocaleLowerCase()) || + (option?.value.toString().toLowerCase() ?? '').includes(input.toLocaleLowerCase()) + } options={options} /> );