diff options
author | Eder Diego de Sousa <me@diego.dev.br> | 2022-07-20 15:50:46 -0300 |
---|---|---|
committer | Eder Diego de Sousa <me@diego.dev.br> | 2022-07-20 15:50:46 -0300 |
commit | 8a1be572100705ba8a21de226ce367f2cb151fa5 (patch) | |
tree | 1993d708ad3050f06e41bed6648b2344709d87d9 /modern/src | |
parent | ce6d3443f224da9099ea7289a1f56a81442bd9f7 (diff) | |
download | trackermap-web-8a1be572100705ba8a21de226ce367f2cb151fa5.tar.gz trackermap-web-8a1be572100705ba8a21de226ce367f2cb151fa5.tar.bz2 trackermap-web-8a1be572100705ba8a21de226ce367f2cb151fa5.zip |
Toast messages translate
Diffstat (limited to 'modern/src')
-rw-r--r-- | modern/src/settings/CalendarPage.js | 6 | ||||
-rw-r--r-- | modern/src/settings/DevicePage.js | 6 |
2 files changed, 10 insertions, 2 deletions
diff --git a/modern/src/settings/CalendarPage.js b/modern/src/settings/CalendarPage.js index cd71e9aa..d9cd895a 100644 --- a/modern/src/settings/CalendarPage.js +++ b/modern/src/settings/CalendarPage.js @@ -66,10 +66,14 @@ const CalendarPage = () => { label={t('sharedName')} /> <DropzoneArea - dropzoneText={t('dropzoneText')} + dropzoneText={t('sharedDropzoneText')} filesLimit={1} onChange={handleFiles} alertSnackbarProps={components.MuiSnackbar.defaultProps} + getFileLimitExceedMessage={(filesLimit) => `${t('sharedMaxFileLimit')} ${t('sharedOnly')} ${filesLimit} ${t('sharedAllowed')}`} + getFileAddedMessage={(fileName) => `${t('sharedFile')} ${fileName} ${t('sharedSuccessfullyAdded')}`} + getFileRemovedMessage={(fileName) => `${t('sharedFile')} ${fileName} ${t('sharedRemoved')}`} + getDropRejectMessage={(file) => `${t('sharedFile')} ${file.name} ${t('sharedDropRejectFile')} ${file.size} ${t('sharedMegabytes')}`} /> </AccordionDetails> </Accordion> diff --git a/modern/src/settings/DevicePage.js b/modern/src/settings/DevicePage.js index 6998288c..f3330040 100644 --- a/modern/src/settings/DevicePage.js +++ b/modern/src/settings/DevicePage.js @@ -150,11 +150,15 @@ const DevicePage = () => { </AccordionSummary> <AccordionDetails className={classes.details}> <DropzoneArea - dropzoneText={t('dropzoneText')} + dropzoneText={t('sharedDropzoneText')} acceptedFiles={['image/*']} filesLimit={1} onChange={handleFiles} alertSnackbarProps={components.MuiSnackbar.defaultProps} + getFileLimitExceedMessage={(filesLimit) => `${t('sharedMaxFileLimit')} ${t('sharedOnly')} ${filesLimit} ${t('sharedAllowed')}`} + getFileAddedMessage={(fileName) => `${t('sharedFile')} ${fileName} ${t('sharedSuccessfullyAdded')}`} + getFileRemovedMessage={(fileName) => `${t('sharedFile')} ${fileName} ${t('sharedRemoved')}`} + getDropRejectMessage={(file) => `${t('sharedFile')} ${file.name} ${t('sharedDropRejectFile')} ${file.size} ${t('sharedMegabytes')}`} /> </AccordionDetails> </Accordion> |