mirror of
https://github.com/appwrite/console.git
synced 2026-06-06 19:27:48 +00:00
fix: prevent bubbling on enter
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
export function clickOnEnter(event: KeyboardEvent) {
|
||||
if (event.key === 'Enter') {
|
||||
if (event.key === 'Enter' && event.target === event.currentTarget) {
|
||||
event.preventDefault();
|
||||
(event.currentTarget as HTMLElement).click();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user