From 3e21aabef3607bee6e32f4d6faddf20731777037 Mon Sep 17 00:00:00 2001 From: Jeff Sieu Date: Wed, 9 Nov 2022 11:02:23 +0800 Subject: [PATCH] [questions][fix] fix CreateListDialog layout --- .../components/questions/CreateListDialog.tsx | 58 ++++++++++--------- 1 file changed, 30 insertions(+), 28 deletions(-) diff --git a/apps/portal/src/components/questions/CreateListDialog.tsx b/apps/portal/src/components/questions/CreateListDialog.tsx index c02e06bd..bd14174a 100644 --- a/apps/portal/src/components/questions/CreateListDialog.tsx +++ b/apps/portal/src/components/questions/CreateListDialog.tsx @@ -31,37 +31,15 @@ export default function CreateListDialog({ reset(); }; + const handleFormSubmit = handleSubmit(async (data) => { + await onSubmit(data); + reset(); + }); + return ( -
{ - await onSubmit(data); - reset(); - })}> -
- -
-