diff options
24 files changed, 376 insertions, 243 deletions
diff --git a/package-lock.json b/package-lock.json index 2a2c83bc9..9a5777658 100644 --- a/package-lock.json +++ b/package-lock.json | |||
@@ -1,6 +1,6 @@ | |||
1 | { | 1 | { |
2 | "name": "franz", | 2 | "name": "franz", |
3 | "version": "5.1.0", | 3 | "version": "5.2.0-beta.1", |
4 | "lockfileVersion": 1, | 4 | "lockfileVersion": 1, |
5 | "requires": true, | 5 | "requires": true, |
6 | "dependencies": { | 6 | "dependencies": { |
@@ -932,12 +932,19 @@ | |||
932 | } | 932 | } |
933 | }, | 933 | }, |
934 | "@babel/polyfill": { | 934 | "@babel/polyfill": { |
935 | "version": "7.2.5", | 935 | "version": "7.4.4", |
936 | "resolved": "https://registry.npmjs.org/@babel/polyfill/-/polyfill-7.2.5.tgz", | 936 | "resolved": "https://registry.npmjs.org/@babel/polyfill/-/polyfill-7.4.4.tgz", |
937 | "integrity": "sha512-8Y/t3MWThtMLYr0YNC/Q76tqN1w30+b0uQMeFUYauG2UGTR19zyUtFrAzT23zNtBxPp+LbE5E/nwV/q/r3y6ug==", | 937 | "integrity": "sha512-WlthFLfhQQhh+A2Gn5NSFl0Huxz36x86Jn+E9OW7ibK8edKPq+KLy4apM1yDpQ8kJOVi1OVjpP4vSDLdrI04dg==", |
938 | "requires": { | 938 | "requires": { |
939 | "core-js": "^2.5.7", | 939 | "core-js": "^2.6.5", |
940 | "regenerator-runtime": "^0.12.0" | 940 | "regenerator-runtime": "^0.13.2" |
941 | }, | ||
942 | "dependencies": { | ||
943 | "core-js": { | ||
944 | "version": "2.6.9", | ||
945 | "resolved": "https://registry.npmjs.org/core-js/-/core-js-2.6.9.tgz", | ||
946 | "integrity": "sha512-HOpZf6eXmnl7la+cUdMnLvUxKNqLUzJvgIziQ0DiF3JwSImNphIqdGqzj6hIKyX04MmV0poclQ7+wjWvxQyR2A==" | ||
947 | } | ||
941 | } | 948 | } |
942 | }, | 949 | }, |
943 | "@babel/preset-env": { | 950 | "@babel/preset-env": { |
@@ -1020,11 +1027,11 @@ | |||
1020 | } | 1027 | } |
1021 | }, | 1028 | }, |
1022 | "@babel/runtime": { | 1029 | "@babel/runtime": { |
1023 | "version": "7.3.1", | 1030 | "version": "7.4.5", |
1024 | "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.3.1.tgz", | 1031 | "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.4.5.tgz", |
1025 | "integrity": "sha512-7jGW8ppV0ant637pIqAcFfQDDH1orEPGJb8aXfUozuCU3QqX7rX4DA8iwrbPrR1hcH0FTTHz47yQnk+bl5xHQA==", | 1032 | "integrity": "sha512-TuI4qpWZP6lGOGIuGWtp9sPluqYICmbk8T/1vpSysqJxRPkudh/ofFWyqdcMsDf2s7KvDL4/YHgKyvcS3g9CJQ==", |
1026 | "requires": { | 1033 | "requires": { |
1027 | "regenerator-runtime": "^0.12.0" | 1034 | "regenerator-runtime": "^0.13.2" |
1028 | } | 1035 | } |
1029 | }, | 1036 | }, |
1030 | "@babel/template": { | 1037 | "@babel/template": { |
@@ -2183,7 +2190,7 @@ | |||
2183 | "@meetfranz/theme": { | 2190 | "@meetfranz/theme": { |
2184 | "version": "file:packages/theme", | 2191 | "version": "file:packages/theme", |
2185 | "requires": { | 2192 | "requires": { |
2186 | "color": "^3.1.0" | 2193 | "color": "3.1.0" |
2187 | } | 2194 | } |
2188 | }, | 2195 | }, |
2189 | "@meetfranz/ui": { | 2196 | "@meetfranz/ui": { |
@@ -2918,7 +2925,7 @@ | |||
2918 | "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", | 2925 | "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", |
2919 | "dev": true, | 2926 | "dev": true, |
2920 | "requires": { | 2927 | "requires": { |
2921 | "ms": "^2.1.1" | 2928 | "ms": "2.1.1" |
2922 | } | 2929 | } |
2923 | }, | 2930 | }, |
2924 | "fs-extra-p": { | 2931 | "fs-extra-p": { |
@@ -4179,7 +4186,7 @@ | |||
4179 | "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", | 4186 | "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", |
4180 | "dev": true, | 4187 | "dev": true, |
4181 | "requires": { | 4188 | "requires": { |
4182 | "ms": "^2.1.1" | 4189 | "ms": "2.1.1" |
4183 | } | 4190 | } |
4184 | }, | 4191 | }, |
4185 | "fs-extra-p": { | 4192 | "fs-extra-p": { |
@@ -4749,8 +4756,8 @@ | |||
4749 | "resolved": "https://registry.npmjs.org/color/-/color-3.1.0.tgz", | 4756 | "resolved": "https://registry.npmjs.org/color/-/color-3.1.0.tgz", |
4750 | "integrity": "sha512-CwyopLkuRYO5ei2EpzpIh6LqJMt6Mt+jZhO5VI5f/wJLZriXQE32/SSqzmrh+QB+AZT81Cj8yv+7zwToW8ahZg==", | 4757 | "integrity": "sha512-CwyopLkuRYO5ei2EpzpIh6LqJMt6Mt+jZhO5VI5f/wJLZriXQE32/SSqzmrh+QB+AZT81Cj8yv+7zwToW8ahZg==", |
4751 | "requires": { | 4758 | "requires": { |
4752 | "color-convert": "^1.9.1", | 4759 | "color-convert": "1.9.3", |
4753 | "color-string": "^1.5.2" | 4760 | "color-string": "1.5.3" |
4754 | } | 4761 | } |
4755 | }, | 4762 | }, |
4756 | "color-convert": { | 4763 | "color-convert": { |
@@ -6801,15 +6808,15 @@ | |||
6801 | "integrity": "sha512-bUHKQhyuOen/q8iHTkrnzqB9CAwBDI+vHbeu21kpq2bqAD+t25yfrmUEcYHaPL4fZOAhk6nnRqskF6/Xd+aZxg==", | 6808 | "integrity": "sha512-bUHKQhyuOen/q8iHTkrnzqB9CAwBDI+vHbeu21kpq2bqAD+t25yfrmUEcYHaPL4fZOAhk6nnRqskF6/Xd+aZxg==", |
6802 | "dev": true, | 6809 | "dev": true, |
6803 | "requires": { | 6810 | "requires": { |
6804 | "@types/node": "^10.12.18", | 6811 | "@types/node": "10.14.4", |
6805 | "electron-download": "^4.1.0", | 6812 | "electron-download": "4.1.1", |
6806 | "extract-zip": "^1.0.3" | 6813 | "extract-zip": "1.6.7" |
6807 | }, | 6814 | }, |
6808 | "dependencies": { | 6815 | "dependencies": { |
6809 | "@types/node": { | 6816 | "@types/node": { |
6810 | "version": "10.14.8", | 6817 | "version": "10.14.4", |
6811 | "resolved": "https://registry.npmjs.org/@types/node/-/node-10.14.8.tgz", | 6818 | "resolved": "https://registry.npmjs.org/@types/node/-/node-10.14.4.tgz", |
6812 | "integrity": "sha512-I4+DbJEhLEg4/vIy/2gkWDvXBOOtPKV9EnLhYjMoqxcRW+TTZtUftkHktz/a8suoD5mUL7m6ReLrkPvSsCQQmw==", | 6819 | "integrity": "sha512-DT25xX/YgyPKiHFOpNuANIQIVvYEwCWXgK2jYYwqgaMrYE6+tq+DtmMwlD3drl6DJbUwtlIDnn0d7tIn/EbXBg==", |
6813 | "dev": true | 6820 | "dev": true |
6814 | } | 6821 | } |
6815 | } | 6822 | } |
@@ -6885,7 +6892,7 @@ | |||
6885 | "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", | 6892 | "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", |
6886 | "dev": true, | 6893 | "dev": true, |
6887 | "requires": { | 6894 | "requires": { |
6888 | "ms": "^2.1.1" | 6895 | "ms": "2.1.1" |
6889 | } | 6896 | } |
6890 | }, | 6897 | }, |
6891 | "fs-extra-p": { | 6898 | "fs-extra-p": { |
@@ -14464,7 +14471,7 @@ | |||
14464 | "integrity": "sha512-1/aa2clS0pue0HjckL62CsbhWWU35HARvBDXcJtYKbYR7LnIutmpxmXbuDMV9kEviD2lP/wACOgWmmwljghHyQ==", | 14471 | "integrity": "sha512-1/aa2clS0pue0HjckL62CsbhWWU35HARvBDXcJtYKbYR7LnIutmpxmXbuDMV9kEviD2lP/wACOgWmmwljghHyQ==", |
14465 | "dev": true, | 14472 | "dev": true, |
14466 | "requires": { | 14473 | "requires": { |
14467 | "semver": "^5.4.1" | 14474 | "semver": "5.6.0" |
14468 | } | 14475 | } |
14469 | }, | 14476 | }, |
14470 | "node-fetch": { | 14477 | "node-fetch": { |
@@ -16792,7 +16799,7 @@ | |||
16792 | "resolved": "https://registry.npmjs.org/react-html-attributes/-/react-html-attributes-1.4.3.tgz", | 16799 | "resolved": "https://registry.npmjs.org/react-html-attributes/-/react-html-attributes-1.4.3.tgz", |
16793 | "integrity": "sha1-jDbDX85rdQk40oavQo7R2nYlGG4=", | 16800 | "integrity": "sha1-jDbDX85rdQk40oavQo7R2nYlGG4=", |
16794 | "requires": { | 16801 | "requires": { |
16795 | "html-element-attributes": "^1.0.0" | 16802 | "html-element-attributes": "1.3.1" |
16796 | } | 16803 | } |
16797 | }, | 16804 | }, |
16798 | "react-intl": { | 16805 | "react-intl": { |
@@ -17253,9 +17260,9 @@ | |||
17253 | } | 17260 | } |
17254 | }, | 17261 | }, |
17255 | "regenerator-runtime": { | 17262 | "regenerator-runtime": { |
17256 | "version": "0.12.1", | 17263 | "version": "0.13.2", |
17257 | "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.12.1.tgz", | 17264 | "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.2.tgz", |
17258 | "integrity": "sha512-odxIc1/vDlo4iZcfXqRYFj0vpXFNoGdKMAUieAlFYO6m/nl5e9KR/beGf41z4a1FI+aQgtjhuaSlDxQ0hmkrHg==" | 17265 | "integrity": "sha512-S/TQAZJO+D3m9xeN1WTI8dLKBBiRgXBlTJvbWjCThHWZj9EvHK70Ff50/tYj2J/fvBY6JtFVwRuazHN2E7M9BA==" |
17259 | }, | 17266 | }, |
17260 | "regenerator-transform": { | 17267 | "regenerator-transform": { |
17261 | "version": "0.13.3", | 17268 | "version": "0.13.3", |
@@ -17327,8 +17334,8 @@ | |||
17327 | "integrity": "sha512-4LM6Fw8eBQdwMYcES4yTnn2TqIasbXuwDx3um+QRs7S55aMKCBKBxvPXl2RiUjHwuJLTyYfxSpmfSAjQpcuP+A==", | 17334 | "integrity": "sha512-4LM6Fw8eBQdwMYcES4yTnn2TqIasbXuwDx3um+QRs7S55aMKCBKBxvPXl2RiUjHwuJLTyYfxSpmfSAjQpcuP+A==", |
17328 | "dev": true, | 17335 | "dev": true, |
17329 | "requires": { | 17336 | "requires": { |
17330 | "rc": "^1.1.6", | 17337 | "rc": "1.2.8", |
17331 | "safe-buffer": "^5.0.1" | 17338 | "safe-buffer": "5.1.2" |
17332 | } | 17339 | } |
17333 | }, | 17340 | }, |
17334 | "registry-url": { | 17341 | "registry-url": { |
@@ -20407,6 +20414,11 @@ | |||
20407 | "builtins": "^1.0.3" | 20414 | "builtins": "^1.0.3" |
20408 | } | 20415 | } |
20409 | }, | 20416 | }, |
20417 | "validator": { | ||
20418 | "version": "11.0.0", | ||
20419 | "resolved": "https://registry.npmjs.org/validator/-/validator-11.0.0.tgz", | ||
20420 | "integrity": "sha512-+wnGLYqaKV2++nUv60uGzUJyJQwYVOin6pn1tgEiFCeCQO60yeu3Og9/yPccbBX574kxIcEJicogkzx6s6eyag==" | ||
20421 | }, | ||
20410 | "value-or-function": { | 20422 | "value-or-function": { |
20411 | "version": "3.0.0", | 20423 | "version": "3.0.0", |
20412 | "resolved": "https://registry.npmjs.org/value-or-function/-/value-or-function-3.0.0.tgz", | 20424 | "resolved": "https://registry.npmjs.org/value-or-function/-/value-or-function-3.0.0.tgz", |
diff --git a/package.json b/package.json index d03de2f20..3df95362d 100644 --- a/package.json +++ b/package.json | |||
@@ -2,7 +2,7 @@ | |||
2 | "name": "franz", | 2 | "name": "franz", |
3 | "productName": "Franz", | 3 | "productName": "Franz", |
4 | "appId": "com.meetfranz.franz", | 4 | "appId": "com.meetfranz.franz", |
5 | "version": "5.1.0", | 5 | "version": "5.2.0-beta.1", |
6 | "description": "Messaging app for WhatsApp, Slack, Telegram, HipChat, Hangouts and many many more.", | 6 | "description": "Messaging app for WhatsApp, Slack, Telegram, HipChat, Hangouts and many many more.", |
7 | "copyright": "adlk x franz - Stefan Malzner", | 7 | "copyright": "adlk x franz - Stefan Malzner", |
8 | "main": "index.js", | 8 | "main": "index.js", |
@@ -34,8 +34,8 @@ | |||
34 | "author": "Stefan Malzner <stefan@adlk.io>", | 34 | "author": "Stefan Malzner <stefan@adlk.io>", |
35 | "license": "Apache-2.0", | 35 | "license": "Apache-2.0", |
36 | "dependencies": { | 36 | "dependencies": { |
37 | "@babel/polyfill": "^7.0.0", | 37 | "@babel/polyfill": "7.4.4", |
38 | "@babel/runtime": "^7.0.0", | 38 | "@babel/runtime": "7.4.5", |
39 | "@meetfranz/electron-notification-state": "1.0.0", | 39 | "@meetfranz/electron-notification-state": "1.0.0", |
40 | "@meetfranz/forms": "file:packages/forms", | 40 | "@meetfranz/forms": "file:packages/forms", |
41 | "@meetfranz/theme": "file:packages/theme", | 41 | "@meetfranz/theme": "file:packages/theme", |
@@ -86,6 +86,7 @@ | |||
86 | "smoothscroll-polyfill": "^0.3.4", | 86 | "smoothscroll-polyfill": "^0.3.4", |
87 | "tar": "^4.0.2", | 87 | "tar": "^4.0.2", |
88 | "uuid": "^3.0.1", | 88 | "uuid": "^3.0.1", |
89 | "validator": "11.0.0", | ||
89 | "ws": "6.2.1" | 90 | "ws": "6.2.1" |
90 | }, | 91 | }, |
91 | "devDependencies": { | 92 | "devDependencies": { |
diff --git a/src/assets/images/tray/win32/tray-unread.ico b/src/assets/images/tray/win32/tray-unread.ico index a59428cfb..507845120 100644 --- a/src/assets/images/tray/win32/tray-unread.ico +++ b/src/assets/images/tray/win32/tray-unread.ico | |||
Binary files differ | |||
diff --git a/src/assets/images/tray/win32/tray-unread@2x.ico b/src/assets/images/tray/win32/tray-unread@2x.ico deleted file mode 100644 index f6fe65093..000000000 --- a/src/assets/images/tray/win32/tray-unread@2x.ico +++ /dev/null | |||
Binary files differ | |||
diff --git a/src/assets/images/tray/win32/tray.ico b/src/assets/images/tray/win32/tray.ico index d3aa25d68..1f0057a8c 100644 --- a/src/assets/images/tray/win32/tray.ico +++ b/src/assets/images/tray/win32/tray.ico | |||
Binary files differ | |||
diff --git a/src/assets/images/tray/win32/tray@2x.ico b/src/assets/images/tray/win32/tray@2x.ico deleted file mode 100644 index c1b7a73a5..000000000 --- a/src/assets/images/tray/win32/tray@2x.ico +++ /dev/null | |||
Binary files differ | |||
diff --git a/src/components/AppUpdateInfoBar.js b/src/components/AppUpdateInfoBar.js new file mode 100644 index 000000000..4fb3a8b71 --- /dev/null +++ b/src/components/AppUpdateInfoBar.js | |||
@@ -0,0 +1,66 @@ | |||
1 | import React, { Component } from 'react'; | ||
2 | import PropTypes from 'prop-types'; | ||
3 | import { defineMessages, intlShape } from 'react-intl'; | ||
4 | |||
5 | import { announcementActions } from '../features/announcements/actions'; | ||
6 | import InfoBar from './ui/InfoBar'; | ||
7 | |||
8 | const messages = defineMessages({ | ||
9 | updateAvailable: { | ||
10 | id: 'infobar.updateAvailable', | ||
11 | defaultMessage: '!!!A new update for Franz is available.', | ||
12 | }, | ||
13 | changelog: { | ||
14 | id: 'infobar.buttonChangelog', | ||
15 | defaultMessage: '!!!Changelog', | ||
16 | }, | ||
17 | buttonInstallUpdate: { | ||
18 | id: 'infobar.buttonInstallUpdate', | ||
19 | defaultMessage: '!!!Restart & install update', | ||
20 | }, | ||
21 | }); | ||
22 | |||
23 | class AppUpdateInfoBar extends Component { | ||
24 | static propTypes = { | ||
25 | onInstallUpdate: PropTypes.func.isRequired, | ||
26 | nextAppReleaseVersion: PropTypes.string, | ||
27 | }; | ||
28 | |||
29 | static defaultProps = { | ||
30 | nextAppReleaseVersion: null, | ||
31 | }; | ||
32 | |||
33 | static contextTypes = { | ||
34 | intl: intlShape, | ||
35 | }; | ||
36 | |||
37 | render() { | ||
38 | const { intl } = this.context; | ||
39 | const { | ||
40 | onInstallUpdate, | ||
41 | nextAppReleaseVersion, | ||
42 | } = this.props; | ||
43 | |||
44 | return ( | ||
45 | <InfoBar | ||
46 | type="primary" | ||
47 | ctaLabel={intl.formatMessage(messages.buttonInstallUpdate)} | ||
48 | onClick={onInstallUpdate} | ||
49 | sticky | ||
50 | > | ||
51 | <span className="mdi mdi-information" /> | ||
52 | {intl.formatMessage(messages.updateAvailable)} | ||
53 | {' '} | ||
54 | <button | ||
55 | className="info-bar__inline-button" | ||
56 | type="button" | ||
57 | onClick={() => announcementActions.show({ targetVersion: nextAppReleaseVersion })} | ||
58 | > | ||
59 | <u>{intl.formatMessage(messages.changelog)}</u> | ||
60 | </button> | ||
61 | </InfoBar> | ||
62 | ); | ||
63 | } | ||
64 | } | ||
65 | |||
66 | export default AppUpdateInfoBar; | ||
diff --git a/src/components/auth/AuthLayout.js b/src/components/auth/AuthLayout.js index ac8fdbe5b..3d43d4e5c 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" |
diff --git a/src/components/layout/AppLayout.js b/src/components/layout/AppLayout.js index b31c00f54..499bc097a 100644 --- a/src/components/layout/AppLayout.js +++ b/src/components/layout/AppLayout.js | |||
@@ -16,7 +16,7 @@ import ErrorBoundary from '../util/ErrorBoundary'; | |||
16 | import { isWindows } from '../../environment'; | 16 | import { isWindows } from '../../environment'; |
17 | import WorkspaceSwitchingIndicator from '../../features/workspaces/components/WorkspaceSwitchingIndicator'; | 17 | import WorkspaceSwitchingIndicator from '../../features/workspaces/components/WorkspaceSwitchingIndicator'; |
18 | import { workspaceStore } from '../../features/workspaces'; | 18 | import { workspaceStore } from '../../features/workspaces'; |
19 | import { announcementActions } from '../../features/announcements/actions'; | 19 | import AppUpdateInfoBar from '../AppUpdateInfoBar'; |
20 | 20 | ||
21 | function createMarkup(HTMLString) { | 21 | function createMarkup(HTMLString) { |
22 | return { __html: HTMLString }; | 22 | return { __html: HTMLString }; |
@@ -27,22 +27,10 @@ const messages = defineMessages({ | |||
27 | id: 'infobar.servicesUpdated', | 27 | id: 'infobar.servicesUpdated', |
28 | defaultMessage: '!!!Your services have been updated.', | 28 | defaultMessage: '!!!Your services have been updated.', |
29 | }, | 29 | }, |
30 | updateAvailable: { | ||
31 | id: 'infobar.updateAvailable', | ||
32 | defaultMessage: '!!!A new update for Franz is available.', | ||
33 | }, | ||
34 | buttonReloadServices: { | 30 | buttonReloadServices: { |
35 | id: 'infobar.buttonReloadServices', | 31 | id: 'infobar.buttonReloadServices', |
36 | defaultMessage: '!!!Reload services', | 32 | defaultMessage: '!!!Reload services', |
37 | }, | 33 | }, |
38 | changelog: { | ||
39 | id: 'infobar.buttonChangelog', | ||
40 | defaultMessage: '!!!Changelog', | ||
41 | }, | ||
42 | buttonInstallUpdate: { | ||
43 | id: 'infobar.buttonInstallUpdate', | ||
44 | defaultMessage: '!!!Restart & install update', | ||
45 | }, | ||
46 | requiredRequestsFailed: { | 34 | requiredRequestsFailed: { |
47 | id: 'infobar.requiredRequestsFailed', | 35 | id: 'infobar.requiredRequestsFailed', |
48 | defaultMessage: '!!!Could not load services and user information', | 36 | defaultMessage: '!!!Could not load services and user information', |
@@ -173,23 +161,10 @@ class AppLayout extends Component { | |||
173 | </InfoBar> | 161 | </InfoBar> |
174 | )} | 162 | )} |
175 | {appUpdateIsDownloaded && ( | 163 | {appUpdateIsDownloaded && ( |
176 | <InfoBar | 164 | <AppUpdateInfoBar |
177 | type="primary" | 165 | nextAppReleaseVersion={nextAppReleaseVersion} |
178 | ctaLabel={intl.formatMessage(messages.buttonInstallUpdate)} | 166 | onInstallUpdate={installAppUpdate} |
179 | onClick={installAppUpdate} | 167 | /> |
180 | sticky | ||
181 | > | ||
182 | <span className="mdi mdi-information" /> | ||
183 | {intl.formatMessage(messages.updateAvailable)} | ||
184 | {' '} | ||
185 | <button | ||
186 | className="info-bar__inline-button" | ||
187 | type="button" | ||
188 | onClick={() => announcementActions.show({ targetVersion: nextAppReleaseVersion })} | ||
189 | > | ||
190 | <u>{intl.formatMessage(messages.changelog)}</u> | ||
191 | </button> | ||
192 | </InfoBar> | ||
193 | )} | 168 | )} |
194 | {isDelayAppScreenVisible && (<DelayApp />)} | 169 | {isDelayAppScreenVisible && (<DelayApp />)} |
195 | <BasicAuth /> | 170 | <BasicAuth /> |
diff --git a/src/containers/auth/AuthLayoutContainer.js b/src/containers/auth/AuthLayoutContainer.js index e63f40c06..1f9c1ea61 100644 --- a/src/containers/auth/AuthLayoutContainer.js +++ b/src/containers/auth/AuthLayoutContainer.js | |||
@@ -51,6 +51,9 @@ export default @inject('stores', 'actions') @observer class AuthLayoutContainer | |||
51 | isHealthCheckLoading={app.healthCheckRequest.isExecuting} | 51 | isHealthCheckLoading={app.healthCheckRequest.isExecuting} |
52 | isFullScreen={app.isFullScreen} | 52 | isFullScreen={app.isFullScreen} |
53 | darkMode={app.isSystemDarkModeEnabled} | 53 | darkMode={app.isSystemDarkModeEnabled} |
54 | installAppUpdate={actions.app.installUpdate} | ||
55 | nextAppReleaseVersion={app.nextAppReleaseVersion} | ||
56 | appUpdateIsDownloaded={app.updateStatus === app.updateStatusTypes.DOWNLOADED} | ||
54 | > | 57 | > |
55 | {children} | 58 | {children} |
56 | </AuthLayout> | 59 | </AuthLayout> |
diff --git a/src/containers/subscription/SubscriptionPopupScreen.js b/src/containers/subscription/SubscriptionPopupScreen.js index 6641f236d..f76d6c5a6 100644 --- a/src/containers/subscription/SubscriptionPopupScreen.js +++ b/src/containers/subscription/SubscriptionPopupScreen.js | |||
@@ -13,7 +13,7 @@ export default @inject('stores', 'actions') @observer class SubscriptionPopupScr | |||
13 | completeCheck(event) { | 13 | completeCheck(event) { |
14 | const { url } = event; | 14 | const { url } = event; |
15 | 15 | ||
16 | if (url.includes('recurly') && url.includes('confirmation')) { | 16 | if ((url.includes('recurly') && url.includes('confirmation')) || (url.includes('meetfranz') && url.includes('success'))) { |
17 | this.setState({ | 17 | this.setState({ |
18 | complete: true, | 18 | complete: true, |
19 | }); | 19 | }); |
diff --git a/src/dev-app-update.yml b/src/dev-app-update.yml new file mode 100644 index 000000000..8ddca71e3 --- /dev/null +++ b/src/dev-app-update.yml | |||
@@ -0,0 +1,3 @@ | |||
1 | owner: meetfranz | ||
2 | repo: franz | ||
3 | provider: github | ||
diff --git a/src/features/workspaces/store.js b/src/features/workspaces/store.js index 51a7f3651..07b16ff23 100644 --- a/src/features/workspaces/store.js +++ b/src/features/workspaces/store.js | |||
@@ -312,17 +312,16 @@ export default class WorkspacesStore extends FeatureStore { | |||
312 | 312 | ||
313 | _cleanupInvalidServiceReferences = () => { | 313 | _cleanupInvalidServiceReferences = () => { |
314 | const { services } = this.stores; | 314 | const { services } = this.stores; |
315 | let invalidServiceReferencesExist = false; | 315 | const { allServicesRequest } = services; |
316 | const servicesHaveBeenLoaded = allServicesRequest.wasExecuted && !allServicesRequest.isError; | ||
317 | // Loop through all workspaces and remove invalid service ids (locally) | ||
316 | this.workspaces.forEach((workspace) => { | 318 | this.workspaces.forEach((workspace) => { |
317 | workspace.services.forEach((serviceId) => { | 319 | workspace.services.forEach((serviceId) => { |
318 | if (!services.one(serviceId)) { | 320 | if (servicesHaveBeenLoaded && !services.one(serviceId)) { |
319 | invalidServiceReferencesExist = true; | 321 | workspace.services.remove(serviceId); |
320 | } | 322 | } |
321 | }); | 323 | }); |
322 | }); | 324 | }); |
323 | if (invalidServiceReferencesExist) { | ||
324 | getUserWorkspacesRequest.execute(); | ||
325 | } | ||
326 | }; | 325 | }; |
327 | 326 | ||
328 | _stopPremiumActionsAndReactions = () => { | 327 | _stopPremiumActionsAndReactions = () => { |
diff --git a/src/helpers/validation-helpers.js b/src/helpers/validation-helpers.js index 2f762437d..ab2376b1b 100644 --- a/src/helpers/validation-helpers.js +++ b/src/helpers/validation-helpers.js | |||
@@ -1,4 +1,5 @@ | |||
1 | import { defineMessages } from 'react-intl'; | 1 | import { defineMessages } from 'react-intl'; |
2 | import isEmail from 'validator/lib/isEmail'; | ||
2 | 3 | ||
3 | const messages = defineMessages({ | 4 | const messages = defineMessages({ |
4 | required: { | 5 | required: { |
@@ -30,14 +31,7 @@ export function required({ field }) { | |||
30 | 31 | ||
31 | export function email({ field }) { | 32 | export function email({ field }) { |
32 | const value = field.value.trim(); | 33 | const value = field.value.trim(); |
33 | let isValid = false; | 34 | const isValid = isEmail(value); |
34 | |||
35 | if (value !== '') { | ||
36 | isValid = Boolean(value.match(/[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,63}/i)); | ||
37 | } else { | ||
38 | isValid = true; | ||
39 | } | ||
40 | |||
41 | return [isValid, window.franz.intl.formatMessage(messages.email, { field: field.label })]; | 35 | return [isValid, window.franz.intl.formatMessage(messages.email, { field: field.label })]; |
42 | } | 36 | } |
43 | 37 | ||
diff --git a/src/i18n/locales/defaultMessages.json b/src/i18n/locales/defaultMessages.json index 9524238f0..d517b456b 100644 --- a/src/i18n/locales/defaultMessages.json +++ b/src/i18n/locales/defaultMessages.json | |||
@@ -2,6 +2,50 @@ | |||
2 | { | 2 | { |
3 | "descriptors": [ | 3 | "descriptors": [ |
4 | { | 4 | { |
5 | "defaultMessage": "!!!A new update for Franz is available.", | ||
6 | "end": { | ||
7 | "column": 3, | ||
8 | "line": 12 | ||
9 | }, | ||
10 | "file": "src/components/AppUpdateInfoBar.js", | ||
11 | "id": "infobar.updateAvailable", | ||
12 | "start": { | ||
13 | "column": 19, | ||
14 | "line": 9 | ||
15 | } | ||
16 | }, | ||
17 | { | ||
18 | "defaultMessage": "!!!Changelog", | ||
19 | "end": { | ||
20 | "column": 3, | ||
21 | "line": 16 | ||
22 | }, | ||
23 | "file": "src/components/AppUpdateInfoBar.js", | ||
24 | "id": "infobar.buttonChangelog", | ||
25 | "start": { | ||
26 | "column": 13, | ||
27 | "line": 13 | ||
28 | } | ||
29 | }, | ||
30 | { | ||
31 | "defaultMessage": "!!!Restart & install update", | ||
32 | "end": { | ||
33 | "column": 3, | ||
34 | "line": 20 | ||
35 | }, | ||
36 | "file": "src/components/AppUpdateInfoBar.js", | ||
37 | "id": "infobar.buttonInstallUpdate", | ||
38 | "start": { | ||
39 | "column": 23, | ||
40 | "line": 17 | ||
41 | } | ||
42 | } | ||
43 | ], | ||
44 | "path": "src/components/AppUpdateInfoBar.json" | ||
45 | }, | ||
46 | { | ||
47 | "descriptors": [ | ||
48 | { | ||
5 | "defaultMessage": "!!!Import your Franz 4 services", | 49 | "defaultMessage": "!!!Import your Franz 4 services", |
6 | "end": { | 50 | "end": { |
7 | "column": 3, | 51 | "column": 3, |
@@ -635,68 +679,29 @@ | |||
635 | } | 679 | } |
636 | }, | 680 | }, |
637 | { | 681 | { |
638 | "defaultMessage": "!!!A new update for Franz is available.", | ||
639 | "end": { | ||
640 | "column": 3, | ||
641 | "line": 33 | ||
642 | }, | ||
643 | "file": "src/components/layout/AppLayout.js", | ||
644 | "id": "infobar.updateAvailable", | ||
645 | "start": { | ||
646 | "column": 19, | ||
647 | "line": 30 | ||
648 | } | ||
649 | }, | ||
650 | { | ||
651 | "defaultMessage": "!!!Reload services", | 682 | "defaultMessage": "!!!Reload services", |
652 | "end": { | 683 | "end": { |
653 | "column": 3, | 684 | "column": 3, |
654 | "line": 37 | 685 | "line": 33 |
655 | }, | 686 | }, |
656 | "file": "src/components/layout/AppLayout.js", | 687 | "file": "src/components/layout/AppLayout.js", |
657 | "id": "infobar.buttonReloadServices", | 688 | "id": "infobar.buttonReloadServices", |
658 | "start": { | 689 | "start": { |
659 | "column": 24, | 690 | "column": 24, |
660 | "line": 34 | 691 | "line": 30 |
661 | } | ||
662 | }, | ||
663 | { | ||
664 | "defaultMessage": "!!!Changelog", | ||
665 | "end": { | ||
666 | "column": 3, | ||
667 | "line": 41 | ||
668 | }, | ||
669 | "file": "src/components/layout/AppLayout.js", | ||
670 | "id": "infobar.buttonChangelog", | ||
671 | "start": { | ||
672 | "column": 13, | ||
673 | "line": 38 | ||
674 | } | ||
675 | }, | ||
676 | { | ||
677 | "defaultMessage": "!!!Restart & install update", | ||
678 | "end": { | ||
679 | "column": 3, | ||
680 | "line": 45 | ||
681 | }, | ||
682 | "file": "src/components/layout/AppLayout.js", | ||
683 | "id": "infobar.buttonInstallUpdate", | ||
684 | "start": { | ||
685 | "column": 23, | ||
686 | "line": 42 | ||
687 | } | 692 | } |
688 | }, | 693 | }, |
689 | { | 694 | { |
690 | "defaultMessage": "!!!Could not load services and user information", | 695 | "defaultMessage": "!!!Could not load services and user information", |
691 | "end": { | 696 | "end": { |
692 | "column": 3, | 697 | "column": 3, |
693 | "line": 49 | 698 | "line": 37 |
694 | }, | 699 | }, |
695 | "file": "src/components/layout/AppLayout.js", | 700 | "file": "src/components/layout/AppLayout.js", |
696 | "id": "infobar.requiredRequestsFailed", | 701 | "id": "infobar.requiredRequestsFailed", |
697 | "start": { | 702 | "start": { |
698 | "column": 26, | 703 | "column": 26, |
699 | "line": 46 | 704 | "line": 34 |
700 | } | 705 | } |
701 | } | 706 | } |
702 | ], | 707 | ], |
@@ -3759,65 +3764,65 @@ | |||
3759 | "defaultMessage": "!!!Field is required", | 3764 | "defaultMessage": "!!!Field is required", |
3760 | "end": { | 3765 | "end": { |
3761 | "column": 3, | 3766 | "column": 3, |
3762 | "line": 7 | 3767 | "line": 8 |
3763 | }, | 3768 | }, |
3764 | "file": "src/helpers/validation-helpers.js", | 3769 | "file": "src/helpers/validation-helpers.js", |
3765 | "id": "validation.required", | 3770 | "id": "validation.required", |
3766 | "start": { | 3771 | "start": { |
3767 | "column": 12, | 3772 | "column": 12, |
3768 | "line": 4 | 3773 | "line": 5 |
3769 | } | 3774 | } |
3770 | }, | 3775 | }, |
3771 | { | 3776 | { |
3772 | "defaultMessage": "!!!Email not valid", | 3777 | "defaultMessage": "!!!Email not valid", |
3773 | "end": { | 3778 | "end": { |
3774 | "column": 3, | 3779 | "column": 3, |
3775 | "line": 11 | 3780 | "line": 12 |
3776 | }, | 3781 | }, |
3777 | "file": "src/helpers/validation-helpers.js", | 3782 | "file": "src/helpers/validation-helpers.js", |
3778 | "id": "validation.email", | 3783 | "id": "validation.email", |
3779 | "start": { | 3784 | "start": { |
3780 | "column": 9, | 3785 | "column": 9, |
3781 | "line": 8 | 3786 | "line": 9 |
3782 | } | 3787 | } |
3783 | }, | 3788 | }, |
3784 | { | 3789 | { |
3785 | "defaultMessage": "!!!Not a valid URL", | 3790 | "defaultMessage": "!!!Not a valid URL", |
3786 | "end": { | 3791 | "end": { |
3787 | "column": 3, | 3792 | "column": 3, |
3788 | "line": 15 | 3793 | "line": 16 |
3789 | }, | 3794 | }, |
3790 | "file": "src/helpers/validation-helpers.js", | 3795 | "file": "src/helpers/validation-helpers.js", |
3791 | "id": "validation.url", | 3796 | "id": "validation.url", |
3792 | "start": { | 3797 | "start": { |
3793 | "column": 7, | 3798 | "column": 7, |
3794 | "line": 12 | 3799 | "line": 13 |
3795 | } | 3800 | } |
3796 | }, | 3801 | }, |
3797 | { | 3802 | { |
3798 | "defaultMessage": "!!!Too few characters", | 3803 | "defaultMessage": "!!!Too few characters", |
3799 | "end": { | 3804 | "end": { |
3800 | "column": 3, | 3805 | "column": 3, |
3801 | "line": 19 | 3806 | "line": 20 |
3802 | }, | 3807 | }, |
3803 | "file": "src/helpers/validation-helpers.js", | 3808 | "file": "src/helpers/validation-helpers.js", |
3804 | "id": "validation.minLength", | 3809 | "id": "validation.minLength", |
3805 | "start": { | 3810 | "start": { |
3806 | "column": 13, | 3811 | "column": 13, |
3807 | "line": 16 | 3812 | "line": 17 |
3808 | } | 3813 | } |
3809 | }, | 3814 | }, |
3810 | { | 3815 | { |
3811 | "defaultMessage": "!!!At least one is required", | 3816 | "defaultMessage": "!!!At least one is required", |
3812 | "end": { | 3817 | "end": { |
3813 | "column": 3, | 3818 | "column": 3, |
3814 | "line": 23 | 3819 | "line": 24 |
3815 | }, | 3820 | }, |
3816 | "file": "src/helpers/validation-helpers.js", | 3821 | "file": "src/helpers/validation-helpers.js", |
3817 | "id": "validation.oneRequired", | 3822 | "id": "validation.oneRequired", |
3818 | "start": { | 3823 | "start": { |
3819 | "column": 15, | 3824 | "column": 15, |
3820 | "line": 20 | 3825 | "line": 21 |
3821 | } | 3826 | } |
3822 | } | 3827 | } |
3823 | ], | 3828 | ], |
@@ -4416,185 +4421,198 @@ | |||
4416 | } | 4421 | } |
4417 | }, | 4422 | }, |
4418 | { | 4423 | { |
4419 | "defaultMessage": "!!!Hide", | 4424 | "defaultMessage": "!!!Check for updates", |
4420 | "end": { | 4425 | "end": { |
4421 | "column": 3, | 4426 | "column": 3, |
4422 | "line": 174 | 4427 | "line": 174 |
4423 | }, | 4428 | }, |
4424 | "file": "src/lib/Menu.js", | 4429 | "file": "src/lib/Menu.js", |
4430 | "id": "menu.app.checkForUpdates", | ||
4431 | "start": { | ||
4432 | "column": 19, | ||
4433 | "line": 171 | ||
4434 | } | ||
4435 | }, | ||
4436 | { | ||
4437 | "defaultMessage": "!!!Hide", | ||
4438 | "end": { | ||
4439 | "column": 3, | ||
4440 | "line": 178 | ||
4441 | }, | ||
4442 | "file": "src/lib/Menu.js", | ||
4425 | "id": "menu.app.hide", | 4443 | "id": "menu.app.hide", |
4426 | "start": { | 4444 | "start": { |
4427 | "column": 8, | 4445 | "column": 8, |
4428 | "line": 171 | 4446 | "line": 175 |
4429 | } | 4447 | } |
4430 | }, | 4448 | }, |
4431 | { | 4449 | { |
4432 | "defaultMessage": "!!!Hide Others", | 4450 | "defaultMessage": "!!!Hide Others", |
4433 | "end": { | 4451 | "end": { |
4434 | "column": 3, | 4452 | "column": 3, |
4435 | "line": 178 | 4453 | "line": 182 |
4436 | }, | 4454 | }, |
4437 | "file": "src/lib/Menu.js", | 4455 | "file": "src/lib/Menu.js", |
4438 | "id": "menu.app.hideOthers", | 4456 | "id": "menu.app.hideOthers", |
4439 | "start": { | 4457 | "start": { |
4440 | "column": 14, | 4458 | "column": 14, |
4441 | "line": 175 | 4459 | "line": 179 |
4442 | } | 4460 | } |
4443 | }, | 4461 | }, |
4444 | { | 4462 | { |
4445 | "defaultMessage": "!!!Unhide", | 4463 | "defaultMessage": "!!!Unhide", |
4446 | "end": { | 4464 | "end": { |
4447 | "column": 3, | 4465 | "column": 3, |
4448 | "line": 182 | 4466 | "line": 186 |
4449 | }, | 4467 | }, |
4450 | "file": "src/lib/Menu.js", | 4468 | "file": "src/lib/Menu.js", |
4451 | "id": "menu.app.unhide", | 4469 | "id": "menu.app.unhide", |
4452 | "start": { | 4470 | "start": { |
4453 | "column": 10, | 4471 | "column": 10, |
4454 | "line": 179 | 4472 | "line": 183 |
4455 | } | 4473 | } |
4456 | }, | 4474 | }, |
4457 | { | 4475 | { |
4458 | "defaultMessage": "!!!Quit", | 4476 | "defaultMessage": "!!!Quit", |
4459 | "end": { | 4477 | "end": { |
4460 | "column": 3, | 4478 | "column": 3, |
4461 | "line": 186 | 4479 | "line": 190 |
4462 | }, | 4480 | }, |
4463 | "file": "src/lib/Menu.js", | 4481 | "file": "src/lib/Menu.js", |
4464 | "id": "menu.app.quit", | 4482 | "id": "menu.app.quit", |
4465 | "start": { | 4483 | "start": { |
4466 | "column": 8, | 4484 | "column": 8, |
4467 | "line": 183 | 4485 | "line": 187 |
4468 | } | 4486 | } |
4469 | }, | 4487 | }, |
4470 | { | 4488 | { |
4471 | "defaultMessage": "!!!Add New Service...", | 4489 | "defaultMessage": "!!!Add New Service...", |
4472 | "end": { | 4490 | "end": { |
4473 | "column": 3, | 4491 | "column": 3, |
4474 | "line": 190 | 4492 | "line": 194 |
4475 | }, | 4493 | }, |
4476 | "file": "src/lib/Menu.js", | 4494 | "file": "src/lib/Menu.js", |
4477 | "id": "menu.services.addNewService", | 4495 | "id": "menu.services.addNewService", |
4478 | "start": { | 4496 | "start": { |
4479 | "column": 17, | 4497 | "column": 17, |
4480 | "line": 187 | 4498 | "line": 191 |
4481 | } | 4499 | } |
4482 | }, | 4500 | }, |
4483 | { | 4501 | { |
4484 | "defaultMessage": "!!!Add New Workspace...", | 4502 | "defaultMessage": "!!!Add New Workspace...", |
4485 | "end": { | 4503 | "end": { |
4486 | "column": 3, | 4504 | "column": 3, |
4487 | "line": 194 | 4505 | "line": 198 |
4488 | }, | 4506 | }, |
4489 | "file": "src/lib/Menu.js", | 4507 | "file": "src/lib/Menu.js", |
4490 | "id": "menu.workspaces.addNewWorkspace", | 4508 | "id": "menu.workspaces.addNewWorkspace", |
4491 | "start": { | 4509 | "start": { |
4492 | "column": 19, | 4510 | "column": 19, |
4493 | "line": 191 | 4511 | "line": 195 |
4494 | } | 4512 | } |
4495 | }, | 4513 | }, |
4496 | { | 4514 | { |
4497 | "defaultMessage": "!!!Open workspace drawer", | 4515 | "defaultMessage": "!!!Open workspace drawer", |
4498 | "end": { | 4516 | "end": { |
4499 | "column": 3, | 4517 | "column": 3, |
4500 | "line": 198 | 4518 | "line": 202 |
4501 | }, | 4519 | }, |
4502 | "file": "src/lib/Menu.js", | 4520 | "file": "src/lib/Menu.js", |
4503 | "id": "menu.workspaces.openWorkspaceDrawer", | 4521 | "id": "menu.workspaces.openWorkspaceDrawer", |
4504 | "start": { | 4522 | "start": { |
4505 | "column": 23, | 4523 | "column": 23, |
4506 | "line": 195 | 4524 | "line": 199 |
4507 | } | 4525 | } |
4508 | }, | 4526 | }, |
4509 | { | 4527 | { |
4510 | "defaultMessage": "!!!Close workspace drawer", | 4528 | "defaultMessage": "!!!Close workspace drawer", |
4511 | "end": { | 4529 | "end": { |
4512 | "column": 3, | 4530 | "column": 3, |
4513 | "line": 202 | 4531 | "line": 206 |
4514 | }, | 4532 | }, |
4515 | "file": "src/lib/Menu.js", | 4533 | "file": "src/lib/Menu.js", |
4516 | "id": "menu.workspaces.closeWorkspaceDrawer", | 4534 | "id": "menu.workspaces.closeWorkspaceDrawer", |
4517 | "start": { | 4535 | "start": { |
4518 | "column": 24, | 4536 | "column": 24, |
4519 | "line": 199 | 4537 | "line": 203 |
4520 | } | 4538 | } |
4521 | }, | 4539 | }, |
4522 | { | 4540 | { |
4523 | "defaultMessage": "!!!Activate next service...", | 4541 | "defaultMessage": "!!!Activate next service...", |
4524 | "end": { | 4542 | "end": { |
4525 | "column": 3, | 4543 | "column": 3, |
4526 | "line": 206 | 4544 | "line": 210 |
4527 | }, | 4545 | }, |
4528 | "file": "src/lib/Menu.js", | 4546 | "file": "src/lib/Menu.js", |
4529 | "id": "menu.services.setNextServiceActive", | 4547 | "id": "menu.services.setNextServiceActive", |
4530 | "start": { | 4548 | "start": { |
4531 | "column": 23, | 4549 | "column": 23, |
4532 | "line": 203 | 4550 | "line": 207 |
4533 | } | 4551 | } |
4534 | }, | 4552 | }, |
4535 | { | 4553 | { |
4536 | "defaultMessage": "!!!Activate previous service...", | 4554 | "defaultMessage": "!!!Activate previous service...", |
4537 | "end": { | 4555 | "end": { |
4538 | "column": 3, | 4556 | "column": 3, |
4539 | "line": 210 | 4557 | "line": 214 |
4540 | }, | 4558 | }, |
4541 | "file": "src/lib/Menu.js", | 4559 | "file": "src/lib/Menu.js", |
4542 | "id": "menu.services.activatePreviousService", | 4560 | "id": "menu.services.activatePreviousService", |
4543 | "start": { | 4561 | "start": { |
4544 | "column": 27, | 4562 | "column": 27, |
4545 | "line": 207 | 4563 | "line": 211 |
4546 | } | 4564 | } |
4547 | }, | 4565 | }, |
4548 | { | 4566 | { |
4549 | "defaultMessage": "!!!Disable notifications & audio", | 4567 | "defaultMessage": "!!!Disable notifications & audio", |
4550 | "end": { | 4568 | "end": { |
4551 | "column": 3, | 4569 | "column": 3, |
4552 | "line": 214 | 4570 | "line": 218 |
4553 | }, | 4571 | }, |
4554 | "file": "src/lib/Menu.js", | 4572 | "file": "src/lib/Menu.js", |
4555 | "id": "sidebar.muteApp", | 4573 | "id": "sidebar.muteApp", |
4556 | "start": { | 4574 | "start": { |
4557 | "column": 11, | 4575 | "column": 11, |
4558 | "line": 211 | 4576 | "line": 215 |
4559 | } | 4577 | } |
4560 | }, | 4578 | }, |
4561 | { | 4579 | { |
4562 | "defaultMessage": "!!!Enable notifications & audio", | 4580 | "defaultMessage": "!!!Enable notifications & audio", |
4563 | "end": { | 4581 | "end": { |
4564 | "column": 3, | 4582 | "column": 3, |
4565 | "line": 218 | 4583 | "line": 222 |
4566 | }, | 4584 | }, |
4567 | "file": "src/lib/Menu.js", | 4585 | "file": "src/lib/Menu.js", |
4568 | "id": "sidebar.unmuteApp", | 4586 | "id": "sidebar.unmuteApp", |
4569 | "start": { | 4587 | "start": { |
4570 | "column": 13, | 4588 | "column": 13, |
4571 | "line": 215 | 4589 | "line": 219 |
4572 | } | 4590 | } |
4573 | }, | 4591 | }, |
4574 | { | 4592 | { |
4575 | "defaultMessage": "!!!Workspaces", | 4593 | "defaultMessage": "!!!Workspaces", |
4576 | "end": { | 4594 | "end": { |
4577 | "column": 3, | 4595 | "column": 3, |
4578 | "line": 222 | 4596 | "line": 226 |
4579 | }, | 4597 | }, |
4580 | "file": "src/lib/Menu.js", | 4598 | "file": "src/lib/Menu.js", |
4581 | "id": "menu.workspaces", | 4599 | "id": "menu.workspaces", |
4582 | "start": { | 4600 | "start": { |
4583 | "column": 14, | 4601 | "column": 14, |
4584 | "line": 219 | 4602 | "line": 223 |
4585 | } | 4603 | } |
4586 | }, | 4604 | }, |
4587 | { | 4605 | { |
4588 | "defaultMessage": "!!!Default", | 4606 | "defaultMessage": "!!!Default", |
4589 | "end": { | 4607 | "end": { |
4590 | "column": 3, | 4608 | "column": 3, |
4591 | "line": 226 | 4609 | "line": 230 |
4592 | }, | 4610 | }, |
4593 | "file": "src/lib/Menu.js", | 4611 | "file": "src/lib/Menu.js", |
4594 | "id": "menu.workspaces.defaultWorkspace", | 4612 | "id": "menu.workspaces.defaultWorkspace", |
4595 | "start": { | 4613 | "start": { |
4596 | "column": 20, | 4614 | "column": 20, |
4597 | "line": 223 | 4615 | "line": 227 |
4598 | } | 4616 | } |
4599 | } | 4617 | } |
4600 | ], | 4618 | ], |
diff --git a/src/i18n/locales/en-US.json b/src/i18n/locales/en-US.json index 6c2759dcc..e2edbd596 100644 --- a/src/i18n/locales/en-US.json +++ b/src/i18n/locales/en-US.json | |||
@@ -45,6 +45,7 @@ | |||
45 | "login.tokenExpired": "Your session expired, please login again.", | 45 | "login.tokenExpired": "Your session expired, please login again.", |
46 | "menu.app.about": "About Franz", | 46 | "menu.app.about": "About Franz", |
47 | "menu.app.announcement": "What's new?", | 47 | "menu.app.announcement": "What's new?", |
48 | "menu.app.checkForUpdates": "Check for updates", | ||
48 | "menu.app.hide": "Hide", | 49 | "menu.app.hide": "Hide", |
49 | "menu.app.hideOthers": "Hide Others", | 50 | "menu.app.hideOthers": "Hide Others", |
50 | "menu.app.quit": "Quit", | 51 | "menu.app.quit": "Quit", |
diff --git a/src/i18n/messages/src/components/AppUpdateInfoBar.json b/src/i18n/messages/src/components/AppUpdateInfoBar.json new file mode 100644 index 000000000..c4c2d0cae --- /dev/null +++ b/src/i18n/messages/src/components/AppUpdateInfoBar.json | |||
@@ -0,0 +1,41 @@ | |||
1 | [ | ||
2 | { | ||
3 | "id": "infobar.updateAvailable", | ||
4 | "defaultMessage": "!!!A new update for Franz is available.", | ||
5 | "file": "src/components/AppUpdateInfoBar.js", | ||
6 | "start": { | ||
7 | "line": 9, | ||
8 | "column": 19 | ||
9 | }, | ||
10 | "end": { | ||
11 | "line": 12, | ||
12 | "column": 3 | ||
13 | } | ||
14 | }, | ||
15 | { | ||
16 | "id": "infobar.buttonChangelog", | ||
17 | "defaultMessage": "!!!Changelog", | ||
18 | "file": "src/components/AppUpdateInfoBar.js", | ||
19 | "start": { | ||
20 | "line": 13, | ||
21 | "column": 13 | ||
22 | }, | ||
23 | "end": { | ||
24 | "line": 16, | ||
25 | "column": 3 | ||
26 | } | ||
27 | }, | ||
28 | { | ||
29 | "id": "infobar.buttonInstallUpdate", | ||
30 | "defaultMessage": "!!!Restart & install update", | ||
31 | "file": "src/components/AppUpdateInfoBar.js", | ||
32 | "start": { | ||
33 | "line": 17, | ||
34 | "column": 23 | ||
35 | }, | ||
36 | "end": { | ||
37 | "line": 20, | ||
38 | "column": 3 | ||
39 | } | ||
40 | } | ||
41 | ] \ No newline at end of file | ||
diff --git a/src/i18n/messages/src/components/layout/AppLayout.json b/src/i18n/messages/src/components/layout/AppLayout.json index 4dd354afc..190c5dff7 100644 --- a/src/i18n/messages/src/components/layout/AppLayout.json +++ b/src/i18n/messages/src/components/layout/AppLayout.json | |||
@@ -13,54 +13,15 @@ | |||
13 | } | 13 | } |
14 | }, | 14 | }, |
15 | { | 15 | { |
16 | "id": "infobar.updateAvailable", | ||
17 | "defaultMessage": "!!!A new update for Franz is available.", | ||
18 | "file": "src/components/layout/AppLayout.js", | ||
19 | "start": { | ||
20 | "line": 30, | ||
21 | "column": 19 | ||
22 | }, | ||
23 | "end": { | ||
24 | "line": 33, | ||
25 | "column": 3 | ||
26 | } | ||
27 | }, | ||
28 | { | ||
29 | "id": "infobar.buttonReloadServices", | 16 | "id": "infobar.buttonReloadServices", |
30 | "defaultMessage": "!!!Reload services", | 17 | "defaultMessage": "!!!Reload services", |
31 | "file": "src/components/layout/AppLayout.js", | 18 | "file": "src/components/layout/AppLayout.js", |
32 | "start": { | 19 | "start": { |
33 | "line": 34, | 20 | "line": 30, |
34 | "column": 24 | 21 | "column": 24 |
35 | }, | 22 | }, |
36 | "end": { | 23 | "end": { |
37 | "line": 37, | 24 | "line": 33, |
38 | "column": 3 | ||
39 | } | ||
40 | }, | ||
41 | { | ||
42 | "id": "infobar.buttonChangelog", | ||
43 | "defaultMessage": "!!!Changelog", | ||
44 | "file": "src/components/layout/AppLayout.js", | ||
45 | "start": { | ||
46 | "line": 38, | ||
47 | "column": 13 | ||
48 | }, | ||
49 | "end": { | ||
50 | "line": 41, | ||
51 | "column": 3 | ||
52 | } | ||
53 | }, | ||
54 | { | ||
55 | "id": "infobar.buttonInstallUpdate", | ||
56 | "defaultMessage": "!!!Restart & install update", | ||
57 | "file": "src/components/layout/AppLayout.js", | ||
58 | "start": { | ||
59 | "line": 42, | ||
60 | "column": 23 | ||
61 | }, | ||
62 | "end": { | ||
63 | "line": 45, | ||
64 | "column": 3 | 25 | "column": 3 |
65 | } | 26 | } |
66 | }, | 27 | }, |
@@ -69,11 +30,11 @@ | |||
69 | "defaultMessage": "!!!Could not load services and user information", | 30 | "defaultMessage": "!!!Could not load services and user information", |
70 | "file": "src/components/layout/AppLayout.js", | 31 | "file": "src/components/layout/AppLayout.js", |
71 | "start": { | 32 | "start": { |
72 | "line": 46, | 33 | "line": 34, |
73 | "column": 26 | 34 | "column": 26 |
74 | }, | 35 | }, |
75 | "end": { | 36 | "end": { |
76 | "line": 49, | 37 | "line": 37, |
77 | "column": 3 | 38 | "column": 3 |
78 | } | 39 | } |
79 | } | 40 | } |
diff --git a/src/i18n/messages/src/helpers/validation-helpers.json b/src/i18n/messages/src/helpers/validation-helpers.json index 86bfe1500..6be1d33e9 100644 --- a/src/i18n/messages/src/helpers/validation-helpers.json +++ b/src/i18n/messages/src/helpers/validation-helpers.json | |||
@@ -4,11 +4,11 @@ | |||
4 | "defaultMessage": "!!!Field is required", | 4 | "defaultMessage": "!!!Field is required", |
5 | "file": "src/helpers/validation-helpers.js", | 5 | "file": "src/helpers/validation-helpers.js", |
6 | "start": { | 6 | "start": { |
7 | "line": 4, | 7 | "line": 5, |
8 | "column": 12 | 8 | "column": 12 |
9 | }, | 9 | }, |
10 | "end": { | 10 | "end": { |
11 | "line": 7, | 11 | "line": 8, |
12 | "column": 3 | 12 | "column": 3 |
13 | } | 13 | } |
14 | }, | 14 | }, |
@@ -17,11 +17,11 @@ | |||
17 | "defaultMessage": "!!!Email not valid", | 17 | "defaultMessage": "!!!Email not valid", |
18 | "file": "src/helpers/validation-helpers.js", | 18 | "file": "src/helpers/validation-helpers.js", |
19 | "start": { | 19 | "start": { |
20 | "line": 8, | 20 | "line": 9, |
21 | "column": 9 | 21 | "column": 9 |
22 | }, | 22 | }, |
23 | "end": { | 23 | "end": { |
24 | "line": 11, | 24 | "line": 12, |
25 | "column": 3 | 25 | "column": 3 |
26 | } | 26 | } |
27 | }, | 27 | }, |
@@ -30,11 +30,11 @@ | |||
30 | "defaultMessage": "!!!Not a valid URL", | 30 | "defaultMessage": "!!!Not a valid URL", |
31 | "file": "src/helpers/validation-helpers.js", | 31 | "file": "src/helpers/validation-helpers.js", |
32 | "start": { | 32 | "start": { |
33 | "line": 12, | 33 | "line": 13, |
34 | "column": 7 | 34 | "column": 7 |
35 | }, | 35 | }, |
36 | "end": { | 36 | "end": { |
37 | "line": 15, | 37 | "line": 16, |
38 | "column": 3 | 38 | "column": 3 |
39 | } | 39 | } |
40 | }, | 40 | }, |
@@ -43,11 +43,11 @@ | |||
43 | "defaultMessage": "!!!Too few characters", | 43 | "defaultMessage": "!!!Too few characters", |
44 | "file": "src/helpers/validation-helpers.js", | 44 | "file": "src/helpers/validation-helpers.js", |
45 | "start": { | 45 | "start": { |
46 | "line": 16, | 46 | "line": 17, |
47 | "column": 13 | 47 | "column": 13 |
48 | }, | 48 | }, |
49 | "end": { | 49 | "end": { |
50 | "line": 19, | 50 | "line": 20, |
51 | "column": 3 | 51 | "column": 3 |
52 | } | 52 | } |
53 | }, | 53 | }, |
@@ -56,11 +56,11 @@ | |||
56 | "defaultMessage": "!!!At least one is required", | 56 | "defaultMessage": "!!!At least one is required", |
57 | "file": "src/helpers/validation-helpers.js", | 57 | "file": "src/helpers/validation-helpers.js", |
58 | "start": { | 58 | "start": { |
59 | "line": 20, | 59 | "line": 21, |
60 | "column": 15 | 60 | "column": 15 |
61 | }, | 61 | }, |
62 | "end": { | 62 | "end": { |
63 | "line": 23, | 63 | "line": 24, |
64 | "column": 3 | 64 | "column": 3 |
65 | } | 65 | } |
66 | } | 66 | } |
diff --git a/src/i18n/messages/src/lib/Menu.json b/src/i18n/messages/src/lib/Menu.json index 2adf5b787..daafb0900 100644 --- a/src/i18n/messages/src/lib/Menu.json +++ b/src/i18n/messages/src/lib/Menu.json | |||
@@ -507,15 +507,28 @@ | |||
507 | } | 507 | } |
508 | }, | 508 | }, |
509 | { | 509 | { |
510 | "id": "menu.app.checkForUpdates", | ||
511 | "defaultMessage": "!!!Check for updates", | ||
512 | "file": "src/lib/Menu.js", | ||
513 | "start": { | ||
514 | "line": 171, | ||
515 | "column": 19 | ||
516 | }, | ||
517 | "end": { | ||
518 | "line": 174, | ||
519 | "column": 3 | ||
520 | } | ||
521 | }, | ||
522 | { | ||
510 | "id": "menu.app.hide", | 523 | "id": "menu.app.hide", |
511 | "defaultMessage": "!!!Hide", | 524 | "defaultMessage": "!!!Hide", |
512 | "file": "src/lib/Menu.js", | 525 | "file": "src/lib/Menu.js", |
513 | "start": { | 526 | "start": { |
514 | "line": 171, | 527 | "line": 175, |
515 | "column": 8 | 528 | "column": 8 |
516 | }, | 529 | }, |
517 | "end": { | 530 | "end": { |
518 | "line": 174, | 531 | "line": 178, |
519 | "column": 3 | 532 | "column": 3 |
520 | } | 533 | } |
521 | }, | 534 | }, |
@@ -524,11 +537,11 @@ | |||
524 | "defaultMessage": "!!!Hide Others", | 537 | "defaultMessage": "!!!Hide Others", |
525 | "file": "src/lib/Menu.js", | 538 | "file": "src/lib/Menu.js", |
526 | "start": { | 539 | "start": { |
527 | "line": 175, | 540 | "line": 179, |
528 | "column": 14 | 541 | "column": 14 |
529 | }, | 542 | }, |
530 | "end": { | 543 | "end": { |
531 | "line": 178, | 544 | "line": 182, |
532 | "column": 3 | 545 | "column": 3 |
533 | } | 546 | } |
534 | }, | 547 | }, |
@@ -537,11 +550,11 @@ | |||
537 | "defaultMessage": "!!!Unhide", | 550 | "defaultMessage": "!!!Unhide", |
538 | "file": "src/lib/Menu.js", | 551 | "file": "src/lib/Menu.js", |
539 | "start": { | 552 | "start": { |
540 | "line": 179, | 553 | "line": 183, |
541 | "column": 10 | 554 | "column": 10 |
542 | }, | 555 | }, |
543 | "end": { | 556 | "end": { |
544 | "line": 182, | 557 | "line": 186, |
545 | "column": 3 | 558 | "column": 3 |
546 | } | 559 | } |
547 | }, | 560 | }, |
@@ -550,11 +563,11 @@ | |||
550 | "defaultMessage": "!!!Quit", | 563 | "defaultMessage": "!!!Quit", |
551 | "file": "src/lib/Menu.js", | 564 | "file": "src/lib/Menu.js", |
552 | "start": { | 565 | "start": { |
553 | "line": 183, | 566 | "line": 187, |
554 | "column": 8 | 567 | "column": 8 |
555 | }, | 568 | }, |
556 | "end": { | 569 | "end": { |
557 | "line": 186, | 570 | "line": 190, |
558 | "column": 3 | 571 | "column": 3 |
559 | } | 572 | } |
560 | }, | 573 | }, |
@@ -563,11 +576,11 @@ | |||
563 | "defaultMessage": "!!!Add New Service...", | 576 | "defaultMessage": "!!!Add New Service...", |
564 | "file": "src/lib/Menu.js", | 577 | "file": "src/lib/Menu.js", |
565 | "start": { | 578 | "start": { |
566 | "line": 187, | 579 | "line": 191, |
567 | "column": 17 | 580 | "column": 17 |
568 | }, | 581 | }, |
569 | "end": { | 582 | "end": { |
570 | "line": 190, | 583 | "line": 194, |
571 | "column": 3 | 584 | "column": 3 |
572 | } | 585 | } |
573 | }, | 586 | }, |
@@ -576,11 +589,11 @@ | |||
576 | "defaultMessage": "!!!Add New Workspace...", | 589 | "defaultMessage": "!!!Add New Workspace...", |
577 | "file": "src/lib/Menu.js", | 590 | "file": "src/lib/Menu.js", |
578 | "start": { | 591 | "start": { |
579 | "line": 191, | 592 | "line": 195, |
580 | "column": 19 | 593 | "column": 19 |
581 | }, | 594 | }, |
582 | "end": { | 595 | "end": { |
583 | "line": 194, | 596 | "line": 198, |
584 | "column": 3 | 597 | "column": 3 |
585 | } | 598 | } |
586 | }, | 599 | }, |
@@ -589,11 +602,11 @@ | |||
589 | "defaultMessage": "!!!Open workspace drawer", | 602 | "defaultMessage": "!!!Open workspace drawer", |
590 | "file": "src/lib/Menu.js", | 603 | "file": "src/lib/Menu.js", |
591 | "start": { | 604 | "start": { |
592 | "line": 195, | 605 | "line": 199, |
593 | "column": 23 | 606 | "column": 23 |
594 | }, | 607 | }, |
595 | "end": { | 608 | "end": { |
596 | "line": 198, | 609 | "line": 202, |
597 | "column": 3 | 610 | "column": 3 |
598 | } | 611 | } |
599 | }, | 612 | }, |
@@ -602,11 +615,11 @@ | |||
602 | "defaultMessage": "!!!Close workspace drawer", | 615 | "defaultMessage": "!!!Close workspace drawer", |
603 | "file": "src/lib/Menu.js", | 616 | "file": "src/lib/Menu.js", |
604 | "start": { | 617 | "start": { |
605 | "line": 199, | 618 | "line": 203, |
606 | "column": 24 | 619 | "column": 24 |
607 | }, | 620 | }, |
608 | "end": { | 621 | "end": { |
609 | "line": 202, | 622 | "line": 206, |
610 | "column": 3 | 623 | "column": 3 |
611 | } | 624 | } |
612 | }, | 625 | }, |
@@ -615,11 +628,11 @@ | |||
615 | "defaultMessage": "!!!Activate next service...", | 628 | "defaultMessage": "!!!Activate next service...", |
616 | "file": "src/lib/Menu.js", | 629 | "file": "src/lib/Menu.js", |
617 | "start": { | 630 | "start": { |
618 | "line": 203, | 631 | "line": 207, |
619 | "column": 23 | 632 | "column": 23 |
620 | }, | 633 | }, |
621 | "end": { | 634 | "end": { |
622 | "line": 206, | 635 | "line": 210, |
623 | "column": 3 | 636 | "column": 3 |
624 | } | 637 | } |
625 | }, | 638 | }, |
@@ -628,11 +641,11 @@ | |||
628 | "defaultMessage": "!!!Activate previous service...", | 641 | "defaultMessage": "!!!Activate previous service...", |
629 | "file": "src/lib/Menu.js", | 642 | "file": "src/lib/Menu.js", |
630 | "start": { | 643 | "start": { |
631 | "line": 207, | 644 | "line": 211, |
632 | "column": 27 | 645 | "column": 27 |
633 | }, | 646 | }, |
634 | "end": { | 647 | "end": { |
635 | "line": 210, | 648 | "line": 214, |
636 | "column": 3 | 649 | "column": 3 |
637 | } | 650 | } |
638 | }, | 651 | }, |
@@ -641,11 +654,11 @@ | |||
641 | "defaultMessage": "!!!Disable notifications & audio", | 654 | "defaultMessage": "!!!Disable notifications & audio", |
642 | "file": "src/lib/Menu.js", | 655 | "file": "src/lib/Menu.js", |
643 | "start": { | 656 | "start": { |
644 | "line": 211, | 657 | "line": 215, |
645 | "column": 11 | 658 | "column": 11 |
646 | }, | 659 | }, |
647 | "end": { | 660 | "end": { |
648 | "line": 214, | 661 | "line": 218, |
649 | "column": 3 | 662 | "column": 3 |
650 | } | 663 | } |
651 | }, | 664 | }, |
@@ -654,11 +667,11 @@ | |||
654 | "defaultMessage": "!!!Enable notifications & audio", | 667 | "defaultMessage": "!!!Enable notifications & audio", |
655 | "file": "src/lib/Menu.js", | 668 | "file": "src/lib/Menu.js", |
656 | "start": { | 669 | "start": { |
657 | "line": 215, | 670 | "line": 219, |
658 | "column": 13 | 671 | "column": 13 |
659 | }, | 672 | }, |
660 | "end": { | 673 | "end": { |
661 | "line": 218, | 674 | "line": 222, |
662 | "column": 3 | 675 | "column": 3 |
663 | } | 676 | } |
664 | }, | 677 | }, |
@@ -667,11 +680,11 @@ | |||
667 | "defaultMessage": "!!!Workspaces", | 680 | "defaultMessage": "!!!Workspaces", |
668 | "file": "src/lib/Menu.js", | 681 | "file": "src/lib/Menu.js", |
669 | "start": { | 682 | "start": { |
670 | "line": 219, | 683 | "line": 223, |
671 | "column": 14 | 684 | "column": 14 |
672 | }, | 685 | }, |
673 | "end": { | 686 | "end": { |
674 | "line": 222, | 687 | "line": 226, |
675 | "column": 3 | 688 | "column": 3 |
676 | } | 689 | } |
677 | }, | 690 | }, |
@@ -680,11 +693,11 @@ | |||
680 | "defaultMessage": "!!!Default", | 693 | "defaultMessage": "!!!Default", |
681 | "file": "src/lib/Menu.js", | 694 | "file": "src/lib/Menu.js", |
682 | "start": { | 695 | "start": { |
683 | "line": 223, | 696 | "line": 227, |
684 | "column": 20 | 697 | "column": 20 |
685 | }, | 698 | }, |
686 | "end": { | 699 | "end": { |
687 | "line": 226, | 700 | "line": 230, |
688 | "column": 3 | 701 | "column": 3 |
689 | } | 702 | } |
690 | } | 703 | } |
diff --git a/src/lib/Menu.js b/src/lib/Menu.js index da2540274..e0dfd736e 100644 --- a/src/lib/Menu.js +++ b/src/lib/Menu.js | |||
@@ -168,6 +168,10 @@ const menuItems = defineMessages({ | |||
168 | id: 'menu.app.settings', | 168 | id: 'menu.app.settings', |
169 | defaultMessage: '!!!Settings', | 169 | defaultMessage: '!!!Settings', |
170 | }, | 170 | }, |
171 | checkForUpdates: { | ||
172 | id: 'menu.app.checkForUpdates', | ||
173 | defaultMessage: '!!!Check for updates', | ||
174 | }, | ||
171 | hide: { | 175 | hide: { |
172 | id: 'menu.app.hide', | 176 | id: 'menu.app.hide', |
173 | defaultMessage: '!!!Hide', | 177 | defaultMessage: '!!!Hide', |
@@ -500,6 +504,11 @@ const _titleBarTemplateFactory = intl => [ | |||
500 | submenu: [], | 504 | submenu: [], |
501 | }, | 505 | }, |
502 | { | 506 | { |
507 | label: intl.formatMessage(menuItems.workspaces), | ||
508 | submenu: [], | ||
509 | visible: workspaceStore.isFeatureEnabled, | ||
510 | }, | ||
511 | { | ||
503 | label: intl.formatMessage(menuItems.window), | 512 | label: intl.formatMessage(menuItems.window), |
504 | submenu: [ | 513 | submenu: [ |
505 | { | 514 | { |
@@ -638,6 +647,12 @@ export default class FranzMenu { | |||
638 | enabled: this.stores.user.isLoggedIn, | 647 | enabled: this.stores.user.isLoggedIn, |
639 | }, | 648 | }, |
640 | { | 649 | { |
650 | label: intl.formatMessage(menuItems.checkForUpdates), | ||
651 | click: () => { | ||
652 | this.actions.app.checkForUpdates(); | ||
653 | }, | ||
654 | }, | ||
655 | { | ||
641 | type: 'separator', | 656 | type: 'separator', |
642 | }, | 657 | }, |
643 | { | 658 | { |
diff --git a/src/stores/GlobalErrorStore.js b/src/stores/GlobalErrorStore.js index 90bf751c3..7a85c2daa 100644 --- a/src/stores/GlobalErrorStore.js +++ b/src/stores/GlobalErrorStore.js | |||
@@ -18,8 +18,11 @@ export default class GlobalErrorStore extends Store { | |||
18 | this.error = request.error; | 18 | this.error = request.error; |
19 | 19 | ||
20 | if (request.error.json) { | 20 | if (request.error.json) { |
21 | this.response = await request.error.json(); | 21 | try { |
22 | 22 | this.response = await request.error.json(); | |
23 | } catch (error) { | ||
24 | this.response = {}; | ||
25 | } | ||
23 | if (this.error.status === 401) { | 26 | if (this.error.status === 401) { |
24 | this.actions.user.logout({ serverLogout: true }); | 27 | this.actions.user.logout({ serverLogout: true }); |
25 | } | 28 | } |
diff --git a/src/stores/NewsStore.js b/src/stores/NewsStore.js index 6984425df..86e092592 100644 --- a/src/stores/NewsStore.js +++ b/src/stores/NewsStore.js | |||
@@ -16,6 +16,7 @@ export default class NewsStore extends Store { | |||
16 | 16 | ||
17 | // Register action handlers | 17 | // Register action handlers |
18 | this.actions.news.hide.listen(this._hide.bind(this)); | 18 | this.actions.news.hide.listen(this._hide.bind(this)); |
19 | this.actions.user.logout.listen(this._resetNewsRequest.bind(this)); | ||
19 | } | 20 | } |
20 | 21 | ||
21 | setup() { | 22 | setup() { |
@@ -40,4 +41,15 @@ export default class NewsStore extends Store { | |||
40 | remove(result, n => n.id === newsId); | 41 | remove(result, n => n.id === newsId); |
41 | }); | 42 | }); |
42 | } | 43 | } |
44 | |||
45 | /** | ||
46 | * Reset the news request when current user logs out so that when another user | ||
47 | * logs in again without an app restart, the request will be fetched again and | ||
48 | * the news will be shown to the user. | ||
49 | * | ||
50 | * @private | ||
51 | */ | ||
52 | _resetNewsRequest() { | ||
53 | this.latestNewsRequest.reset(); | ||
54 | } | ||
43 | } | 55 | } |
diff --git a/src/stores/UserStore.js b/src/stores/UserStore.js index 31555dd5c..b5423af3b 100644 --- a/src/stores/UserStore.js +++ b/src/stores/UserStore.js | |||
@@ -329,8 +329,7 @@ export default class UserStore extends Store { | |||
329 | authToken, | 329 | authToken, |
330 | }); | 330 | }); |
331 | } catch (err) { | 331 | } catch (err) { |
332 | console.error('AccessToken Invalid'); | 332 | this._logout(); |
333 | |||
334 | return false; | 333 | return false; |
335 | } | 334 | } |
336 | } | 335 | } |