From 0182c467d7e70bcfc31642374fefd32c6bf5a4ee Mon Sep 17 00:00:00 2001 From: Alex Bratsos Date: Sat, 4 Jan 2020 00:19:56 +0200 Subject: [PATCH] fixup! Add event listeners for shapes shortcuts --- src/index.tsx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/index.tsx b/src/index.tsx index cc91d144d..4dd1c5307 100644 --- a/src/index.tsx +++ b/src/index.tsx @@ -118,6 +118,8 @@ function hitTest(element: ExcalidrawElement, x: number, y: number): boolean { const y2 = getElementAbsoluteY2(element); return x >= x1 && x <= x2 && y >= y1 && y <= y2; + } else if (element.type === "selection") { + return false; } else { throw new Error("Unimplemented type " + element.type); }