fix: Escape does not close CMD+K when viewing a document or collection
This commit is contained in:
@@ -59,6 +59,9 @@ function SharePopover({ collection, visible, onRequestClose }: Props) {
|
||||
useKeyDown(
|
||||
"Escape",
|
||||
(ev) => {
|
||||
if (!visible) {
|
||||
return;
|
||||
}
|
||||
ev.preventDefault();
|
||||
ev.stopImmediatePropagation();
|
||||
|
||||
|
||||
@@ -67,6 +67,9 @@ function SharePopover({
|
||||
useKeyDown(
|
||||
"Escape",
|
||||
(ev) => {
|
||||
if (!visible) {
|
||||
return;
|
||||
}
|
||||
ev.preventDefault();
|
||||
ev.stopImmediatePropagation();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user