diff --git a/src/Selector/MultipleSelector.tsx b/src/Selector/MultipleSelector.tsx index 8ad89025..68ac1639 100644 --- a/src/Selector/MultipleSelector.tsx +++ b/src/Selector/MultipleSelector.tsx @@ -86,9 +86,7 @@ const SelectSelector: React.FC = (props) => { ? searchValue : ''; const inputEditable: boolean = - mode === 'tags' || - (mode === 'multiple' && autoClearSearchValue === false) || - (showSearch && (open || focused)); + mode === 'tags' || (mode === 'multiple' && showSearch) || (showSearch && (open || focused)); // We measure width and set to the input immediately useLayoutEffect(() => { diff --git a/tests/Multiple.test.tsx b/tests/Multiple.test.tsx index 6e6a051a..7897090f 100644 --- a/tests/Multiple.test.tsx +++ b/tests/Multiple.test.tsx @@ -681,5 +681,16 @@ describe('Select.Multiple', () => { toggleOpen(wrapper); expect(wrapper.find('input').props().value).toBe(''); }); + it('input should be readonly when autoClearSearchValue and showSearch are both false', () => { + const wrapper = mount( +