diff --git a/frontend/package.json b/frontend/package.json index 5ae9bf0..661eb14 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -10,15 +10,15 @@ "dependencies": { "@azure/msal-browser": "^4.26.0", "@emotion/cache": "^11.9.3", - "@emotion/react": "^11.9.3", + "@emotion/react": "^11.14.0", "@fluentui/react-icons": "^2.0.315", "@fluentui/react-icons-mdl2": "^1.4.2", "@honkhonk/vite-plugin-svgr": "^1.1.0", - "@mantine/core": "^5.0.0", + "@mantine/core": "^5.10.5", "@mantine/form": "^5.0.0", - "@mantine/hooks": "^5.0.0", + "@mantine/hooks": "^5.10.5", "@mantine/modals": "^5.10.5", - "@mantine/notifications": "^5.0.0", + "@mantine/notifications": "^5.10.5", "@microsoft/microsoft-graph-client": "^3.0.7", "@reduxjs/toolkit": "^1.8.3", "@visx/glyph": "^2.10.0", diff --git a/frontend/src/components/panels/xdc/CollectionPanel.jsx b/frontend/src/components/panels/xdc/CollectionPanel.jsx index 7c19fb2..9d77c3a 100644 --- a/frontend/src/components/panels/xdc/CollectionPanel.jsx +++ b/frontend/src/components/panels/xdc/CollectionPanel.jsx @@ -30,7 +30,7 @@ export default function CollectionPanel({ id }) { - + setActiveTab(TabValues.RESULTS)}/> diff --git a/frontend/src/components/panels/xdc/CollectionWizard.jsx b/frontend/src/components/panels/xdc/CollectionWizard.jsx index 733891d..677f7d8 100644 --- a/frontend/src/components/panels/xdc/CollectionWizard.jsx +++ b/frontend/src/components/panels/xdc/CollectionWizard.jsx @@ -1,4 +1,5 @@ import { Button, Container, Group, Loader, Space, Stack } from '@mantine/core' +// import { Notifications } from '@mantine/notifications' import { useContext, useState } from 'react' import { usePanelProperty, useOpenPanel } from '../../../redux/hooks/panelsHooks' import { useFile } from '../../../redux/hooks/workingDirectoryHooks' @@ -9,7 +10,7 @@ import { uploadExperiment } from '../../../API' import { showErrorNotification } from '../../../modules/util' import Dropzone from '../../Dropzone' -export default function CollectionWizard() { +export default function CollectionWizard({ onUploadSuccess }) { const panelId = useContext(PanelContext) const openPanel = useOpenPanel() const [dataSBH] = useLocalStorage({ key: 'SynbioHub', defaultValue: [] }) @@ -27,6 +28,7 @@ export default function CollectionWizard() { const [uploads, setUploads] = usePanelProperty(panelId, 'uploads', false, []) const [isSubmitting, setIsSubmitting] = useState(false) + const [uploadSuccess, setUploadSuccess] = useState(false) const selectedRepo = collection?.selectedRepo || collection?.modalResult?.selectedRepo || '' const authToken = collection?.authToken || collection?.modalResult?.authToken || dataSBH.find((repo) => repo.registryURL === selectedRepo)?.authtoken || '' @@ -72,6 +74,18 @@ export default function CollectionWizard() { } setUploads((currentUploads) => [...(currentUploads || []), uploadEntry]) + setUploadSuccess(true) + + // notifications.show({ + // title: 'Upload successful', + // message: 'Your collection has been uploaded.', + // color: 'green', + // action: { + // label: 'See Results', + // onClick: onUploadSuccess + // } + // }) + } catch (error) { showErrorNotification('Upload failed', error?.response?.data?.error || error.message || 'Unable to upload the collection metadata.') } finally { @@ -117,6 +131,17 @@ export default function CollectionWizard() { {isSubmitting ? : uploadLabel} + + {uploadSuccess && ( + + )} + ) } diff --git a/tutorial/~$A_Parts_with_sequences.docx b/tutorial/~$A_Parts_with_sequences.docx new file mode 100644 index 0000000..dccaee7 Binary files /dev/null and b/tutorial/~$A_Parts_with_sequences.docx differ