From afd9f2d30a229fd78f218093a1a53a9ef693e9e6 Mon Sep 17 00:00:00 2001 From: Mitchell McCaffrey Date: Fri, 6 Aug 2021 08:34:27 +1000 Subject: [PATCH] Adjust token attachment size to be resolution independent --- src/components/konva/TokenAttachment.tsx | 26 +++++++++++++----------- 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/src/components/konva/TokenAttachment.tsx b/src/components/konva/TokenAttachment.tsx index 902843e..2511094 100644 --- a/src/components/konva/TokenAttachment.tsx +++ b/src/components/konva/TokenAttachment.tsx @@ -13,27 +13,29 @@ function TokenAttachment({ highlight, radius, }: TokenAttachmentProps) { + const width = radius / 3; + const height = radius / 8; return ( {/* Make a bigger hidden rect for hit registration */} {}} /> {dragging ? (