diff options
Diffstat (limited to 'src/components/auth')
-rw-r--r-- | src/components/auth/AuthLayout.js | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/components/auth/AuthLayout.js b/src/components/auth/AuthLayout.js index ac8fdbe5b..9bde58461 100644 --- a/src/components/auth/AuthLayout.js +++ b/src/components/auth/AuthLayout.js | |||
@@ -11,6 +11,7 @@ import { oneOrManyChildElements, globalError as globalErrorPropType } from '../. | |||
11 | import globalMessages from '../../i18n/globalMessages'; | 11 | import globalMessages from '../../i18n/globalMessages'; |
12 | 12 | ||
13 | import { isWindows } from '../../environment'; | 13 | import { isWindows } from '../../environment'; |
14 | import AppUpdateInfoBar from '../AppUpdateInfoBar'; | ||
14 | 15 | ||
15 | export default @observer class AuthLayout extends Component { | 16 | export default @observer class AuthLayout extends Component { |
16 | static propTypes = { | 17 | static propTypes = { |
@@ -22,6 +23,13 @@ export default @observer class AuthLayout extends Component { | |||
22 | isHealthCheckLoading: PropTypes.bool.isRequired, | 23 | isHealthCheckLoading: PropTypes.bool.isRequired, |
23 | isFullScreen: PropTypes.bool.isRequired, | 24 | isFullScreen: PropTypes.bool.isRequired, |
24 | darkMode: PropTypes.bool.isRequired, | 25 | darkMode: PropTypes.bool.isRequired, |
26 | nextAppReleaseVersion: PropTypes.string, | ||
27 | installAppUpdate: PropTypes.func.isRequired, | ||
28 | appUpdateIsDownloaded: PropTypes.bool.isRequired, | ||
29 | }; | ||
30 | |||
31 | static defaultProps = { | ||
32 | nextAppReleaseVersion: null, | ||
25 | }; | 33 | }; |
26 | 34 | ||
27 | static contextTypes = { | 35 | static contextTypes = { |
@@ -38,6 +46,9 @@ export default @observer class AuthLayout extends Component { | |||
38 | isHealthCheckLoading, | 46 | isHealthCheckLoading, |
39 | isFullScreen, | 47 | isFullScreen, |
40 | darkMode, | 48 | darkMode, |
49 | nextAppReleaseVersion, | ||
50 | installAppUpdate, | ||
51 | appUpdateIsDownloaded | ||
41 | } = this.props; | 52 | } = this.props; |
42 | const { intl } = this.context; | 53 | const { intl } = this.context; |
43 | 54 | ||
@@ -53,6 +64,12 @@ export default @observer class AuthLayout extends Component { | |||
53 | {intl.formatMessage(globalMessages.notConnectedToTheInternet)} | 64 | {intl.formatMessage(globalMessages.notConnectedToTheInternet)} |
54 | </InfoBar> | 65 | </InfoBar> |
55 | )} | 66 | )} |
67 | {appUpdateIsDownloaded && ( | ||
68 | <AppUpdateInfoBar | ||
69 | nextAppReleaseVersion={nextAppReleaseVersion} | ||
70 | onInstallUpdate={installAppUpdate} | ||
71 | /> | ||
72 | )} | ||
56 | {isOnline && !isAPIHealthy && ( | 73 | {isOnline && !isAPIHealthy && ( |
57 | <InfoBar | 74 | <InfoBar |
58 | type="danger" | 75 | type="danger" |