diff --git a/web/app/components/datasets/documents/detail/completed/common/drawer.tsx b/web/app/components/datasets/documents/detail/completed/common/drawer.tsx index 34170595db..806eff01f6 100644 --- a/web/app/components/datasets/documents/detail/completed/common/drawer.tsx +++ b/web/app/components/datasets/documents/detail/completed/common/drawer.tsx @@ -32,6 +32,7 @@ const Drawer = ({ const currChildChunk = useSegmentListContext(s => s.currChildChunk) useKeyPress('esc', (e) => { + if (!open) return e.preventDefault() onClose() }, { exactMatch: true, useCapture: true })