diff options
author | Ricardo Cino <ricardo@cino.io> | 2022-06-26 23:59:32 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-26 21:59:32 +0000 |
commit | 6bff2bb5439d25e0ab2a24a8ca1b28b89ef40ff9 (patch) | |
tree | 1676f5eef42b8086d28476c7eaad62c7b1753120 /src/containers/auth/LoginScreen.js | |
parent | Reduce tab item layout shift (#376) (diff) | |
download | ferdium-app-6bff2bb5439d25e0ab2a24a8ca1b28b89ef40ff9.tar.gz ferdium-app-6bff2bb5439d25e0ab2a24a8ca1b28b89ef40ff9.tar.zst ferdium-app-6bff2bb5439d25e0ab2a24a8ca1b28b89ef40ff9.zip |
chore: turned all auth containers into typescript (#375)
Diffstat (limited to 'src/containers/auth/LoginScreen.js')
-rw-r--r-- | src/containers/auth/LoginScreen.js | 41 |
1 files changed, 0 insertions, 41 deletions
diff --git a/src/containers/auth/LoginScreen.js b/src/containers/auth/LoginScreen.js deleted file mode 100644 index f8351f458..000000000 --- a/src/containers/auth/LoginScreen.js +++ /dev/null | |||
@@ -1,41 +0,0 @@ | |||
1 | import { Component } from 'react'; | ||
2 | import PropTypes from 'prop-types'; | ||
3 | import { inject, observer } from 'mobx-react'; | ||
4 | import Login from '../../components/auth/Login'; | ||
5 | import UserStore from '../../stores/UserStore'; | ||
6 | |||
7 | import { globalError as globalErrorPropType } from '../../prop-types'; | ||
8 | |||
9 | class LoginScreen extends Component { | ||
10 | static propTypes = { | ||
11 | error: globalErrorPropType.isRequired, | ||
12 | }; | ||
13 | |||
14 | render() { | ||
15 | const { actions, stores, error } = this.props; | ||
16 | return ( | ||
17 | <Login | ||
18 | onSubmit={actions.user.login} | ||
19 | isSubmitting={stores.user.loginRequest.isExecuting} | ||
20 | isTokenExpired={stores.user.isTokenExpired} | ||
21 | isServerLogout={ | ||
22 | stores.user.logoutReason === stores.user.logoutReasonTypes.SERVER | ||
23 | } | ||
24 | signupRoute={stores.user.signupRoute} | ||
25 | passwordRoute={stores.user.passwordRoute} | ||
26 | error={error} | ||
27 | /> | ||
28 | ); | ||
29 | } | ||
30 | } | ||
31 | |||
32 | LoginScreen.propTypes = { | ||
33 | actions: PropTypes.shape({ | ||
34 | user: PropTypes.instanceOf(UserStore).isRequired, | ||
35 | }).isRequired, | ||
36 | stores: PropTypes.shape({ | ||
37 | user: PropTypes.instanceOf(UserStore).isRequired, | ||
38 | }).isRequired, | ||
39 | }; | ||
40 | |||
41 | export default inject('stores', 'actions')(observer(LoginScreen)); | ||