aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2022-07-20 12:49:49 -0700
committerGitHub <noreply@github.com>2022-07-20 12:49:49 -0700
commit503421e22059140daa6dafbb1e6b0f08918a7757 (patch)
tree45653241eb531a959a8b82b9a14e1bac7c206bcb
parent9e7ca99218cb7176d27a7a2271294e976d885ccd (diff)
parent96ae3dcfc01b0f6200b7dccc3dc1837562685308 (diff)
downloadtrackermap-web-503421e22059140daa6dafbb1e6b0f08918a7757.tar.gz
trackermap-web-503421e22059140daa6dafbb1e6b0f08918a7757.tar.bz2
trackermap-web-503421e22059140daa6dafbb1e6b0f08918a7757.zip
Merge pull request #992 from DiSousaDev/master
Localizing DropzoneArea
-rw-r--r--modern/src/settings/CalendarPage.js4
-rw-r--r--modern/src/settings/DevicePage.js4
-rw-r--r--web/l10n/en.json1
3 files changed, 5 insertions, 4 deletions
diff --git a/modern/src/settings/CalendarPage.js b/modern/src/settings/CalendarPage.js
index 896a77c4..27fdb462 100644
--- a/modern/src/settings/CalendarPage.js
+++ b/modern/src/settings/CalendarPage.js
@@ -10,7 +10,6 @@ import EditItemView from './components/EditItemView';
import EditAttributesAccordion from './components/EditAttributesAccordion';
import { useTranslation } from '../common/components/LocalizationProvider';
import SettingsMenu from './components/SettingsMenu';
-import components from '../common/theme/components';
const useStyles = makeStyles((theme) => ({
details: {
@@ -66,9 +65,10 @@ const CalendarPage = () => {
label={t('sharedName')}
/>
<DropzoneArea
+ dropzoneText={t('sharedDropzoneText')}
filesLimit={1}
onChange={handleFiles}
- alertSnackbarProps={components.MuiSnackbar.defaultProps}
+ showAlerts={false}
/>
</AccordionDetails>
</Accordion>
diff --git a/modern/src/settings/DevicePage.js b/modern/src/settings/DevicePage.js
index d0d5dd5e..bf79109b 100644
--- a/modern/src/settings/DevicePage.js
+++ b/modern/src/settings/DevicePage.js
@@ -24,7 +24,6 @@ import { useAdministrator } from '../common/util/permissions';
import SettingsMenu from './components/SettingsMenu';
import useCommonDeviceAttributes from '../common/attributes/useCommonDeviceAttributes';
import useFeatures from '../common/util/useFeatures';
-import components from '../common/theme/components';
import { useCatch } from '../reactHelper';
const useStyles = makeStyles((theme) => ({
@@ -150,10 +149,11 @@ const DevicePage = () => {
</AccordionSummary>
<AccordionDetails className={classes.details}>
<DropzoneArea
+ dropzoneText={t('sharedDropzoneText')}
acceptedFiles={['image/*']}
filesLimit={1}
onChange={handleFiles}
- alertSnackbarProps={components.MuiSnackbar.defaultProps}
+ showAlerts={false}
/>
</AccordionDetails>
</Accordion>
diff --git a/web/l10n/en.json b/web/l10n/en.json
index 615d2a86..2549a081 100644
--- a/web/l10n/en.json
+++ b/web/l10n/en.json
@@ -93,6 +93,7 @@
"sharedLocation": "Location",
"sharedImport": "Import",
"sharedColumns": "Columns",
+ "sharedDropzoneText": "Drag and drop a file here or click",
"attributeSpeedLimit": "Speed Limit",
"attributePolylineDistance": "Polyline Distance",
"attributeReportIgnoreOdometer": "Report: Ignore Odometer",