Skip to content

Commit 8bd42b6

Browse files
committed
fix(ComboBox): allow selecting by enter * 2
1 parent e287d8b commit 8bd42b6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/components/fields/ComboBox/ComboBox.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -325,7 +325,7 @@ export const ComboBox = forwardRef(function ComboBox<T extends object>(
325325
if (e.key === 'Enter' && !props.allowsCustomValue && state.isOpen) {
326326
const option = [...state.collection][0]?.key;
327327

328-
if (option) {
328+
if (option && selectedKey !== option) {
329329
props.onSelectionChange?.(option);
330330

331331
e.stopPropagation();

0 commit comments

Comments
 (0)