Skip to content

Commit

Permalink
return true (cancel) the enter key event in typeahead (#1804)
Browse files Browse the repository at this point in the history
  • Loading branch information
sawka authored Jan 23, 2025
1 parent e2800b3 commit e3a9b80
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions frontend/app/modals/conntypeahead.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -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);
Expand All @@ -481,6 +483,7 @@ const ChangeConnectionBlockModal = React.memo(
return true;
}
setRowIndex(0);
return false;
},
[changeConnModalAtom, viewModel, blockId, connSelected, selectionList]
);
Expand Down

0 comments on commit e3a9b80

Please sign in to comment.