From 38f8469d0b917fde0f1fb0a0a1ef49f583558fa9 Mon Sep 17 00:00:00 2001 From: Alex Date: Mon, 27 Mar 2023 19:11:57 +0100 Subject: [PATCH 01/10] Update Navigation.tsx --- frontend/src/Navigation.tsx | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/frontend/src/Navigation.tsx b/frontend/src/Navigation.tsx index 979f64ea..a660a135 100644 --- a/frontend/src/Navigation.tsx +++ b/frontend/src/Navigation.tsx @@ -38,9 +38,8 @@ export default function Navigation({ const [isDocsListOpen, setIsDocsListOpen] = useState(false); const isApiKeySet = useSelector(selectApiKeyStatus); - const [apiKeyModalState, setApiKeyModalState] = useState( - isApiKeySet ? 'INACTIVE' : 'ACTIVE', - ); + const [apiKeyModalState, setApiKeyModalState] = + useState('INACTIVE'); const isSelectedDocsSet = useSelector(selectSelectedDocsStatus); const [selectedDocsModalState, setSelectedDocsModalState] = From 658b14ba261cd9ec3bdadf1faf7c3ec07400995b Mon Sep 17 00:00:00 2001 From: Alex Date: Mon, 27 Mar 2023 19:22:06 +0100 Subject: [PATCH 02/10] failed upload --- frontend/src/upload/Upload.tsx | 34 ++++++++++++++++++++++++++++++---- 1 file changed, 30 insertions(+), 4 deletions(-) diff --git a/frontend/src/upload/Upload.tsx b/frontend/src/upload/Upload.tsx index e404bd12..9a0f62d0 100644 --- a/frontend/src/upload/Upload.tsx +++ b/frontend/src/upload/Upload.tsx @@ -19,20 +19,27 @@ export default function Upload({ type: 'UPLOAD' | 'TRAINIING'; percentage: number; taskId?: string; + failed?: boolean; }>(); function Progress({ title, isCancellable = false, + isFailed = false, }: { title: string; isCancellable?: boolean; + isFailed?: boolean; }) { return (

{title}...

This may take several minutes

+

+ Over the token limit, please consider uploading smaller document +

{progress?.percentage || 0}%

+
+