From 4aa6810af6ca5aec1d7d279c1fef826e54ea2f8e Mon Sep 17 00:00:00 2001 From: anovazzi1 Date: Thu, 3 Aug 2023 18:40:17 -0300 Subject: [PATCH] fix(exportModal/index.tsx): add state for invalidName to handle invalid flow names in the export modal feat(exportModal/index.tsx): pass invalidName state and setInvalidName function as props to EditFlowSettings component to handle invalid flow names in the export modal --- src/frontend/src/modals/exportModal/index.tsx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/frontend/src/modals/exportModal/index.tsx b/src/frontend/src/modals/exportModal/index.tsx index ee6434f67..c45723e04 100644 --- a/src/frontend/src/modals/exportModal/index.tsx +++ b/src/frontend/src/modals/exportModal/index.tsx @@ -13,6 +13,7 @@ const ExportModal = forwardRef((props: { children: ReactNode }, ref) => { useContext(TabsContext); const [checked, setChecked] = useState(false); const [name, setName] = useState(flows.find((f) => f.id === tabId).name); + const [invalidName, setInvalidName] = useState(false); const [description, setDescription] = useState( flows.find((f) => f.id === tabId).description ); @@ -30,6 +31,8 @@ const ExportModal = forwardRef((props: { children: ReactNode }, ref) => {