return true (cancel) the enter key event in typeahead (#1804)

This commit is contained in:
Mike Sawka 2025-01-22 18:22:45 -08:00 committed by GitHub
parent e2800b39b6
commit e3a9b80df5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -465,6 +465,8 @@ const ChangeConnectionBlockModal = React.memo(
globalStore.set(changeConnModalAtom, false);
globalRefocusWithTimeout(10);
}
setRowIndex(0);
return true;
}
if (keyutil.checkKeyPressed(waveEvent, "Escape")) {
globalStore.set(changeConnModalAtom, false);
@ -481,6 +483,7 @@ const ChangeConnectionBlockModal = React.memo(
return true;
}
setRowIndex(0);
return false;
},
[changeConnModalAtom, viewModel, blockId, connSelected, selectionList]
);