Skip to content

Commit

Permalink
fix: added transaltion
Browse files Browse the repository at this point in the history
  • Loading branch information
borkopetrovicc committed Jun 15, 2023
1 parent b611a23 commit 3d85038
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
3 changes: 2 additions & 1 deletion public/locales/en/account.json
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,8 @@
"sign_up": "Sign up",
"view_password": "View password",
"wrong_combination": "Incorrect email/password combination",
"wrong_email": "Please check your email and try again."
"wrong_email": "Please check your email and try again.",
"simultaneous_logins": "You have been logged out because the simultaneous logins limit has been reached."
},
"payment": {
"back_to_profile": "Back to profile",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import React from 'react';
import { useLocation, useNavigate } from 'react-router';
import { useTranslation } from 'react-i18next';

import styles from '../AccountModal.module.scss';

Expand All @@ -9,13 +10,14 @@ import { addQueryParam } from '#src/utils/location';
const SimultaneousLoginsNotification = () => {
const navigate = useNavigate();
const location = useLocation();
const { t } = useTranslation('account');
function loginClickHandler() {
navigate(addQueryParam(location, 'u', 'login'));
}

return (
<React.Fragment>
<h1 className={styles.simultaneousLoginsTitle}>You have been logged out because the simultaneous logins limit has been reached.</h1>
<h1 className={styles.simultaneousLoginsTitle}> {t('login.simultaneous_logins')}</h1>
<Button type="submit" onClick={loginClickHandler} label="Ok" variant="contained" color="primary" size="large" fullWidth />
</React.Fragment>
);
Expand Down

0 comments on commit 3d85038

Please sign in to comment.