Skip to content

Commit da31a0c

Browse files
TonybynMp4claude
andcommitted
fix(web): Enter and Space activate the focused context menu item
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
1 parent 20141d7 commit da31a0c

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

‎apps/web/src/contextMenuFallback.ts‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -359,8 +359,10 @@ export function showContextMenuFallback<T extends string>(
359359
return;
360360
case "Enter":
361361
case " ":
362-
isKeyboardDriven = true;
363-
return;
362+
// Keyboard activation must not depend on the opening pointer gesture's frame.
363+
canDismissFromPointer = true;
364+
items[focusedIndex]?.click();
365+
break;
364366
default:
365367
return;
366368
}

0 commit comments

Comments
 (0)