From 245675d409da23fe648873364078fbaab16f9d96 Mon Sep 17 00:00:00 2001 From: Elian Doran Date: Fri, 12 Sep 2025 16:24:35 +0300 Subject: [PATCH] chore(collections/board): reintroduce note click on the board --- apps/client/src/widgets/collections/board/card.tsx | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/apps/client/src/widgets/collections/board/card.tsx b/apps/client/src/widgets/collections/board/card.tsx index 4ad335b4b..165eccc75 100644 --- a/apps/client/src/widgets/collections/board/card.tsx +++ b/apps/client/src/widgets/collections/board/card.tsx @@ -42,7 +42,12 @@ export default function Card({ openNoteContextMenu(api, e, note.noteId, branch.branchId, column); }, [ api, note, branch, column ]); - const handleEdit = useCallback((e) => { + const handleOpen = useCallback(() => { + api.openNote(note.noteId); + }, [ api, note ]); + + const handleEdit = useCallback((e: MouseEvent) => { + e.stopPropagation(); // don't also open the note setBranchIdToEdit?.(branch.branchId); }, [ setBranchIdToEdit, branch ]); @@ -61,6 +66,7 @@ export default function Card({ onDragStart={handleDragStart} onDragEnd={handleDragEnd} onContextMenu={handleContextMenu} + onClick={!isEditing ? handleOpen : undefined} > {!isEditing ? ( <>