diff --git a/public/locales/en/createCollection.json b/public/locales/en/createCollection.json
index 2c701b242..8d14585af 100644
--- a/public/locales/en/createCollection.json
+++ b/public/locales/en/createCollection.json
@@ -7,9 +7,9 @@
"required": "Host Collection is required"
},
"name": {
- "label": "Dataverse Name",
+ "label": "Collection Name",
"description": "The project, department, university, professor, or journal this collection will contain data for.",
- "required": "Dataverse Name is required"
+ "required": "Collection Name is required"
},
"affiliation": {
"label": "Affiliation",
@@ -22,7 +22,8 @@
"invalid": {
"format": "Identifier is not a valid identifier. Valid characters are a-Z, 0-9, '_', and '-'.",
"maxLength": "Identifier must be at most {{maxLength}} characters."
- }
+ },
+ "suggestion": "Psst... try this"
},
"storage": {
"label": "Storage",
diff --git a/src/sections/create-collection/CreateCollection.tsx b/src/sections/create-collection/CreateCollection.tsx
index 29561da9a..32eef981e 100644
--- a/src/sections/create-collection/CreateCollection.tsx
+++ b/src/sections/create-collection/CreateCollection.tsx
@@ -1,11 +1,12 @@
+import { useEffect } from 'react'
+import { useTranslation } from 'react-i18next'
import { useCollection } from '../collection/useCollection'
import { CollectionRepository } from '../../collection/domain/repositories/CollectionRepository'
-import { BreadcrumbsGenerator } from '../shared/hierarchy/BreadcrumbsGenerator'
-import { useTranslation } from 'react-i18next'
-import { RequiredFieldText } from '../shared/form/RequiredFieldText/RequiredFieldText'
-import { CollectionForm, CollectionFormProps } from './collection-form'
-import { useEffect } from 'react'
import { useLoading } from '../loading/LoadingContext'
+import { useSession } from '../session/SessionContext'
+import { RequiredFieldText } from '../shared/form/RequiredFieldText/RequiredFieldText'
+import { BreadcrumbsGenerator } from '../shared/hierarchy/BreadcrumbsGenerator'
+import { CollectionForm, CollectionFormData } from './collection-form'
interface CreateCollectionProps {
ownerCollectionId: string
@@ -18,14 +19,13 @@ export function CreateCollection({
}: CreateCollectionProps) {
const { t } = useTranslation('createCollection')
const { isLoading, setIsLoading } = useLoading()
+ const { user } = useSession()
const { collection, isLoading: isLoadingCollection } = useCollection(
collectionRepository,
ownerCollectionId
)
- console.log({ collection, isLoadingCollection })
-
// TODO:ME If is not loading and collection is not found, show a message and navigate to the root collection
// One good thing would be add toastify to show messages on top of the page for this kind of things
@@ -44,15 +44,15 @@ export function CreateCollection({
return