diff --git a/frontend/app/dashboard/[project-slug]/links/page.tsx b/frontend/app/dashboard/[project-slug]/links/page.tsx index e019a55..6223aee 100644 --- a/frontend/app/dashboard/[project-slug]/links/page.tsx +++ b/frontend/app/dashboard/[project-slug]/links/page.tsx @@ -43,7 +43,7 @@ const LinkPage = () => { useEffect(() => { const keyboardEventHandler = (e: KeyboardEvent) => { - if (e.key === "n" || e.key === "N") { + if ((e.key === "n" || e.key === "N") && !showModal) { e.preventDefault(); openModal(); } @@ -54,7 +54,7 @@ const LinkPage = () => { return () => { window.removeEventListener("keydown", keyboardEventHandler); }; - }, []); + }, [showModal]); return (