summaryrefslogtreecommitdiffstats
path: root/web/react/components/user_settings
diff options
context:
space:
mode:
Diffstat (limited to 'web/react/components/user_settings')
-rw-r--r--web/react/components/user_settings/custom_theme_chooser.jsx2
-rw-r--r--web/react/components/user_settings/user_settings_general.jsx4
2 files changed, 5 insertions, 1 deletions
diff --git a/web/react/components/user_settings/custom_theme_chooser.jsx b/web/react/components/user_settings/custom_theme_chooser.jsx
index 55242ca7f..b7d90922a 100644
--- a/web/react/components/user_settings/custom_theme_chooser.jsx
+++ b/web/react/components/user_settings/custom_theme_chooser.jsx
@@ -92,7 +92,7 @@ export default class CustomThemeChooser extends React.Component {
>
<img
width='200'
- src={'/static/images/themes/code_themes/' + theme[element.id] + 'Large.png'}
+ src={'/static/images/themes/code_themes/' + theme[element.id] + '.png'}
/>
</Popover>
);
diff --git a/web/react/components/user_settings/user_settings_general.jsx b/web/react/components/user_settings/user_settings_general.jsx
index 7c1a1297f..014038dd4 100644
--- a/web/react/components/user_settings/user_settings_general.jsx
+++ b/web/react/components/user_settings/user_settings_general.jsx
@@ -9,6 +9,7 @@ import UserStore from '../../stores/user_store.jsx';
import ErrorStore from '../../stores/error_store.jsx';
import * as Client from '../../utils/client.jsx';
+import Constants from '../../utils/constants.jsx';
import * as AsyncClient from '../../utils/async_client.jsx';
import * as Utils from '../../utils/utils.jsx';
@@ -156,6 +157,9 @@ export default class UserSettingsGeneralTab extends React.Component {
if (picture.type !== 'image/jpeg' && picture.type !== 'image/png') {
this.setState({clientError: 'Only JPG or PNG images may be used for profile pictures.'});
return;
+ } else if (picture.size > Constants.MAX_FILE_SIZE) {
+ this.setState({clientError: 'Unable to upload profile image. File is too large.'});
+ return;
}
var formData = new FormData();