From 438ac0d1f82a95367b374b56f9c61a7a5802735c Mon Sep 17 00:00:00 2001 From: Ivan Chen Date: Tue, 25 May 2021 17:13:12 -0400 Subject: Squashed commit of the following: commit 7711d92c8dab4f00e36ad3bbca9bc202fa313e43 Author: Brian Kim Date: Tue May 25 17:08:41 2021 -0400 Integrate with layering commit cbd01996ae4784b737fb4b634eb0048bb7d85967 Author: Brian Kim Date: Tue May 25 16:48:52 2021 -0400 Fix yarn commit 39164064b903df36b7373e177d00c3307a8a311a Author: Brian Kim Date: Tue May 25 16:46:34 2021 -0400 Add horizontal scroll commit 02841df862aa68dcf615d0264236d9a14b52befe Author: Brian Kim Date: Tue May 25 15:03:13 2021 -0400 Lint fixes commit 5c6e8e453026005f6621efe751d90c76f457a72f Author: Brian Kim Date: Tue May 25 14:46:39 2021 -0400 Set boundaries, fix offset calculation, fix length and height calculation to be individual commit 6d27d859fd5364556928e5a2feadad1aff4dc6b9 Author: Brian Kim Date: Tue May 25 11:32:08 2021 -0400 Pause --- src/components/taggs/TaggDraggable.tsx | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'src/components/taggs') diff --git a/src/components/taggs/TaggDraggable.tsx b/src/components/taggs/TaggDraggable.tsx index 55f8162b..3dd5f230 100644 --- a/src/components/taggs/TaggDraggable.tsx +++ b/src/components/taggs/TaggDraggable.tsx @@ -35,9 +35,13 @@ const TaggDraggable: React.FC = ( const draggableRef = useRef(null); useEffect(() => { - draggableRef.current.measure((width: number, height: number) => { - setStart([width, height]); - }); + setTimeout(() => { + draggableRef.current.measure( + (_1: number, _2: number, width: number, height: number) => { + setStart([width, height]); + }, + ); + }, 250); }, []); const user: UserType = { -- cgit v1.2.3-70-g09d2