Skip to content

Commit

Permalink
CB-5767 removes extra handleEnter for button click enter
Browse files Browse the repository at this point in the history
  • Loading branch information
sergeyteleshev committed Oct 8, 2024
1 parent 6708003 commit 198a5cf
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions webapp/packages/core-blocks/src/Button.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -72,12 +72,6 @@ export const Button = observer<ButtonProps>(function Button({
['click'],
);

function handleEnter(event: React.KeyboardEvent<HTMLElement>) {
if (event.key === 'Enter') {
event.currentTarget.click();
}
}

loading = state.loading || loading;

if (loading) {
Expand All @@ -89,7 +83,6 @@ export const Button = observer<ButtonProps>(function Button({
<Button
role="button"
tabIndex={0}
onKeyDown={handleEnter}
{...rest}
type={type}
disabled={disabled}
Expand Down

0 comments on commit 198a5cf

Please sign in to comment.