Skip to content

Commit

Permalink
updated RequiredFieldText to use translation
Browse files Browse the repository at this point in the history
  • Loading branch information
Matt Mangan committed Jan 5, 2024
1 parent 1a3dd8a commit bdc6e93
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions public/locales/en/createDataset.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"title": "Metadata Tip",
"content": "After adding the dataset, click the Edit Dataset button to add more metadata."
},
"requiredFields": "Asterisks indicate required fields",
"datasetForm": {
"title": "Title"
},
Expand Down
4 changes: 3 additions & 1 deletion src/components/form/RequiredFieldText/RequiredFieldText.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import { RequiredInputSymbol } from '@iqss/dataverse-design-system'
import { useTranslation } from 'react-i18next'

export function RequiredFieldText() {
const { t } = useTranslation('createDataset')
return (
<p>
<RequiredInputSymbol />
Asterisks indicate required fields
{t('requiredFields')}
</p>
)
}

0 comments on commit bdc6e93

Please sign in to comment.